<!--
 * @Descripttion: 
 * @version: 
 * @Author: 王政乔(https://www.zhengqiao.wang/)
 * @Date: 2020-03-25 10:59:52
 * @LastEditors: 王政乔(https://www.zhengqiao.wang/)
 * @LastEditTime: 2020-04-12 19:47:37
 -->
<!DOCTYPE html>
<html  lang="zh">
<head>
    
    <link href="//cdn.bootcss.com/pace/1.0.2/themes/pink/pace-theme-flash.css" rel="stylesheet">

    <style>
        body {
            cursor: url("http://pic.zhengqiao.wang/Arrow.cur"), auto !important;
        }
    
        a:hover {
            cursor: url("http://pic.zhengqiao.wang/Hand.cur"), auto !important;
        }
        input:hover{
            cursor: url("http://pic.zhengqiao.wang/IBeam.cur"), auto !important;
        }
        .pace .pace-progress {
            background: #1E92FB; /*进度条颜色*/
            height: 3px;
        }
        .pace .pace-progress-inner {
            box-shadow: 0 0 10px #1E92FB, 0 0 5px     #1E92FB; /*阴影颜色*/
        }
        .pace .pace-activity {
            border-top-color: #1E92FB;    /*上边框颜色*/
            border-left-color: #1E92FB;    /*左边框颜色*/
        }
    </style>
    <!--
 * @Descripttion: 
 * @version: 
 * @Author: 王政乔(https://www.zhengqiao.wang/)
 * @Date: 2020-03-25 10:59:52
 * @LastEditors: 王政乔(https://www.zhengqiao.wang/)
 * @LastEditTime: 2020-05-06 19:55:13
 -->
<meta charset="utf-8" />

<meta name="generator" content="Hexo 4.2.0" />

<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1" />

<title>编译原理实验三：算符优先算法实现(半成品) - 王政乔|中国</title>
<!-- iconfont -->
<link rel="stylesheet" href="//at.alicdn.com/t/font_1734413_xyuugyshzlp.css">

    <meta name="description" content="编译原理实验三：算符优先算法实现(半成品)还没写完，因为最后实现的部分有bug，但是firstvt、lastvt以及优先表格经过确认无误，但是最后规约出现了冲突问题，正在考虑怎么办，先放上代码，等问题解决了再更新修改～">
<meta property="og:type" content="article">
<meta property="og:title" content="编译原理实验三：算符优先算法实现(半成品)">
<meta property="og:url" content="https://www.zhengqiao.wang/2018-12-06-%E7%BC%96%E8%AF%91%E5%8E%9F%E7%90%86%E5%AE%9E%E9%AA%8C%E4%B8%89/index.html">
<meta property="og:site_name" content="王政乔|中国">
<meta property="og:description" content="编译原理实验三：算符优先算法实现(半成品)还没写完，因为最后实现的部分有bug，但是firstvt、lastvt以及优先表格经过确认无误，但是最后规约出现了冲突问题，正在考虑怎么办，先放上代码，等问题解决了再更新修改～">
<meta property="og:locale" content="zh_CN">
<meta property="og:image" content="https://www.zhengqiao.wang/images/og_image.png">
<meta property="article:published_time" content="2018-12-05T16:00:00.000Z">
<meta property="article:modified_time" content="2020-03-31T12:17:23.508Z">
<meta property="article:author" content="王政乔">
<meta property="article:tag" content="python">
<meta property="article:tag" content="编译原理">
<meta property="article:tag" content="代码存档">
<meta name="twitter:card" content="summary">
<meta name="twitter:image" content="https://www.zhengqiao.wang/images/og_image.png">







<link rel="icon" href="http://pic.zhengqiao.wang/20200301103642.jpg">


<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/bulma@0.7.2/css/bulma.css">

<link rel="stylesheet" href="https://use.fontawesome.com/releases/v5.4.1/css/all.css">

<link rel="stylesheet" href="https://fonts.googleapis.com/css?family=Ubuntu:400,600|Source+Code+Pro">
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/highlight.js@9.12.0/styles/atom-one-light.css">


    
    
<style>body>.footer,body>.navbar,body>.section{opacity:0}</style>

    
    
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/lightgallery@1.6.8/dist/css/lightgallery.min.css">
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/justifiedGallery@3.7.0/dist/css/justifiedGallery.min.css">

    
    
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/outdatedbrowser@1.1.5/outdatedbrowser/outdatedbrowser.min.css">

    
    
    
    
<link rel="stylesheet" href="/css/back-to-top.css">

    
    
    
    <script>
var _hmt = _hmt || [];
(function() {
    var hm = document.createElement("script");
    hm.src = "//hm.baidu.com/hm.js?c62b048aa4e4e717dbea80aaaab32c9e";
    var s = document.getElementsByTagName("script")[0];
    s.parentNode.insertBefore(hm, s);
})();
</script>
    
    
    
    <link rel="stylesheet" href="/css/progressbar.css">
<script src="https://cdn.jsdelivr.net/npm/pace-js@1.0.2/pace.min.js"></script>
    
    
    


<link rel="stylesheet" href="/css/style.css">
</head>
<body class="is-3-column">
    <script src="//cdn.bootcss.com/pace/1.0.2/pace.min.js"></script>
    
        <canvas class="fireworks" style="position: fixed;left: 0;top: 0;z-index: 1; pointer-events: none;"></canvas>
        <script type="text/javascript" src="//cdn.bootcss.com/animejs/2.2.0/anime.min.js"></script>
        <script type="text/javascript" src="/js/fireworks.js"></script>
    
    <!--
 * @Descripttion: 
 * @version: 
 * @Author: 王政乔(https://www.zhengqiao.wang/)
 * @Date: 2020-03-25 10:59:52
 * @LastEditors: 王政乔(https://www.zhengqiao.wang/)
 * @LastEditTime: 2020-04-04 10:57:37
 -->
<nav class="navbar navbar-main">
    <div class="container">
        <div class="navbar-brand is-flex-center">
            <a class="navbar-item navbar-logo" href="/">
            
                王政乔|中国
            
            </a>
        </div>
        <div class="navbar-menu">
            
            <div class="navbar-start">
                
                <a class="navbar-item"
                href="/">主页</a>
                
                <a class="navbar-item"
                href="/archives">文章列表</a>
                
                <a class="navbar-item"
                href="/about">关于我</a>
                
                <a class="navbar-item"
                href="/gallary">图集</a>
                
                <a class="navbar-item"
                href="/jogertools">政乔工具库</a>
                
            </div>
            
            <div class="navbar-end">
                
                    
                    <a class="navbar-item" target="_blank" rel="noopener" title="访问我的Gitee" href="https://gitee.com/JogerQiao">
                        
                        <i class="iconfont icon-gitee-fill-round"></i>
                        
                    </a>
                    
                    <a class="navbar-item" target="_blank" rel="noopener" title="我的邮箱" href="mailto:me@zhengqiao.wang">
                        
                        <i class="iconfont icon-mail"></i>
                        
                    </a>
                    
                    <a class="navbar-item" target="_blank" rel="noopener" title="Bilibili" href="https://space.bilibili.com/83542572">
                        
                        <i class="iconfont icon-bilibili-line"></i>
                        
                    </a>
                    
                    <a class="navbar-item" target="_blank" rel="noopener" title="知乎" href="https://www.zhihu.com/people/joger-81">
                        
                        <i class="iconfont icon-zhihu"></i>
                        
                    </a>
                    
                
                
                <a class="navbar-item is-hidden-tablet catalogue" title="目录" href="javascript:;">
                    <i class="fas fa-list-ul"></i>
                </a>
                
                
                <a class="navbar-item search" title="搜索" href="javascript:;">
                    <i class="iconfont icon-search"></i>
                </a>
                
            </div>
        </div>
    </div>
</nav>
    
    <section class="section">
        <div class="container">
            <div class="columns">
                <div class="column is-8-tablet is-8-desktop is-6-widescreen has-order-2 column-main">
<div class="card">
    
    <div class="card-content article ">
        
        <div class="level article-meta is-size-7 is-uppercase is-mobile is-overflow-x-auto">
            <div class="level-left">
                <time class="level-item has-text-grey" datetime="2018-12-05T16:00:00.000Z">2018年12月06日</time>
                
                <div class="level-item">
                <a class="has-link-grey -link" href="/categories/%E8%AF%BE%E7%A8%8B%E8%AE%BE%E8%AE%A1/">课程设计</a>&nbsp;/&nbsp;<a class="has-link-grey -link" href="/categories/%E8%AF%BE%E7%A8%8B%E8%AE%BE%E8%AE%A1/%E7%BC%96%E8%AF%91%E5%8E%9F%E7%90%86/">编译原理</a>
                </div>
                
                
                <span class="level-item has-text-grey">
                    
                    
                    17 分钟 读完 (大约 2478 个字)
                </span>
                
                
            </div>
        </div>
        
        <h1 class="title is-size-3 is-size-4-mobile has-text-weight-normal">
            
                编译原理实验三：算符优先算法实现(半成品)
            
        </h1>
        <div class="content">
            <h2 id="编译原理实验三：算符优先算法实现-半成品"><a href="#编译原理实验三：算符优先算法实现-半成品" class="headerlink" title="编译原理实验三：算符优先算法实现(半成品)"></a>编译原理实验三：算符优先算法实现(半成品)</h2><p>还没写完，因为最后实现的部分有bug，但是firstvt、lastvt以及优先表格经过确认无误，但是最后规约出现了冲突问题，正在考虑怎么办，先放上代码，等问题解决了再更新修改～</p>
<a id="more"></a>

<p>tc3.py</p>
<figure class="highlight python"><table><tr><td class="gutter"><pre><span class="line">1</span><br><span class="line">2</span><br><span class="line">3</span><br><span class="line">4</span><br><span class="line">5</span><br><span class="line">6</span><br><span class="line">7</span><br><span class="line">8</span><br><span class="line">9</span><br><span class="line">10</span><br><span class="line">11</span><br><span class="line">12</span><br><span class="line">13</span><br><span class="line">14</span><br><span class="line">15</span><br><span class="line">16</span><br><span class="line">17</span><br><span class="line">18</span><br><span class="line">19</span><br><span class="line">20</span><br><span class="line">21</span><br><span class="line">22</span><br><span class="line">23</span><br><span class="line">24</span><br><span class="line">25</span><br><span class="line">26</span><br><span class="line">27</span><br><span class="line">28</span><br><span class="line">29</span><br><span class="line">30</span><br><span class="line">31</span><br><span class="line">32</span><br><span class="line">33</span><br><span class="line">34</span><br><span class="line">35</span><br><span class="line">36</span><br><span class="line">37</span><br><span class="line">38</span><br><span class="line">39</span><br><span class="line">40</span><br><span class="line">41</span><br><span class="line">42</span><br><span class="line">43</span><br><span class="line">44</span><br><span class="line">45</span><br><span class="line">46</span><br><span class="line">47</span><br><span class="line">48</span><br><span class="line">49</span><br><span class="line">50</span><br><span class="line">51</span><br><span class="line">52</span><br><span class="line">53</span><br><span class="line">54</span><br><span class="line">55</span><br><span class="line">56</span><br><span class="line">57</span><br><span class="line">58</span><br><span class="line">59</span><br><span class="line">60</span><br><span class="line">61</span><br><span class="line">62</span><br><span class="line">63</span><br><span class="line">64</span><br><span class="line">65</span><br><span class="line">66</span><br><span class="line">67</span><br><span class="line">68</span><br><span class="line">69</span><br><span class="line">70</span><br><span class="line">71</span><br><span class="line">72</span><br><span class="line">73</span><br><span class="line">74</span><br><span class="line">75</span><br><span class="line">76</span><br><span class="line">77</span><br><span class="line">78</span><br><span class="line">79</span><br><span class="line">80</span><br><span class="line">81</span><br><span class="line">82</span><br><span class="line">83</span><br><span class="line">84</span><br><span class="line">85</span><br><span class="line">86</span><br><span class="line">87</span><br><span class="line">88</span><br><span class="line">89</span><br><span class="line">90</span><br><span class="line">91</span><br><span class="line">92</span><br><span class="line">93</span><br><span class="line">94</span><br><span class="line">95</span><br><span class="line">96</span><br><span class="line">97</span><br><span class="line">98</span><br><span class="line">99</span><br><span class="line">100</span><br><span class="line">101</span><br><span class="line">102</span><br><span class="line">103</span><br><span class="line">104</span><br><span class="line">105</span><br><span class="line">106</span><br><span class="line">107</span><br><span class="line">108</span><br><span class="line">109</span><br><span class="line">110</span><br><span class="line">111</span><br><span class="line">112</span><br><span class="line">113</span><br><span class="line">114</span><br><span class="line">115</span><br><span class="line">116</span><br><span class="line">117</span><br><span class="line">118</span><br><span class="line">119</span><br><span class="line">120</span><br><span class="line">121</span><br><span class="line">122</span><br><span class="line">123</span><br><span class="line">124</span><br><span class="line">125</span><br><span class="line">126</span><br><span class="line">127</span><br><span class="line">128</span><br><span class="line">129</span><br><span class="line">130</span><br><span class="line">131</span><br><span class="line">132</span><br><span class="line">133</span><br><span class="line">134</span><br><span class="line">135</span><br><span class="line">136</span><br><span class="line">137</span><br><span class="line">138</span><br><span class="line">139</span><br><span class="line">140</span><br><span class="line">141</span><br><span class="line">142</span><br><span class="line">143</span><br><span class="line">144</span><br><span class="line">145</span><br><span class="line">146</span><br><span class="line">147</span><br><span class="line">148</span><br><span class="line">149</span><br><span class="line">150</span><br><span class="line">151</span><br><span class="line">152</span><br><span class="line">153</span><br><span class="line">154</span><br><span class="line">155</span><br><span class="line">156</span><br><span class="line">157</span><br><span class="line">158</span><br><span class="line">159</span><br><span class="line">160</span><br><span class="line">161</span><br><span class="line">162</span><br><span class="line">163</span><br><span class="line">164</span><br><span class="line">165</span><br><span class="line">166</span><br><span class="line">167</span><br><span class="line">168</span><br><span class="line">169</span><br><span class="line">170</span><br><span class="line">171</span><br><span class="line">172</span><br><span class="line">173</span><br><span class="line">174</span><br><span class="line">175</span><br><span class="line">176</span><br><span class="line">177</span><br><span class="line">178</span><br><span class="line">179</span><br><span class="line">180</span><br><span class="line">181</span><br><span class="line">182</span><br><span class="line">183</span><br><span class="line">184</span><br><span class="line">185</span><br><span class="line">186</span><br><span class="line">187</span><br><span class="line">188</span><br><span class="line">189</span><br><span class="line">190</span><br><span class="line">191</span><br><span class="line">192</span><br><span class="line">193</span><br><span class="line">194</span><br><span class="line">195</span><br><span class="line">196</span><br><span class="line">197</span><br><span class="line">198</span><br><span class="line">199</span><br><span class="line">200</span><br><span class="line">201</span><br><span class="line">202</span><br><span class="line">203</span><br><span class="line">204</span><br><span class="line">205</span><br><span class="line">206</span><br><span class="line">207</span><br><span class="line">208</span><br><span class="line">209</span><br><span class="line">210</span><br><span class="line">211</span><br><span class="line">212</span><br><span class="line">213</span><br><span class="line">214</span><br><span class="line">215</span><br><span class="line">216</span><br><span class="line">217</span><br><span class="line">218</span><br><span class="line">219</span><br><span class="line">220</span><br><span class="line">221</span><br><span class="line">222</span><br><span class="line">223</span><br><span class="line">224</span><br><span class="line">225</span><br><span class="line">226</span><br><span class="line">227</span><br><span class="line">228</span><br><span class="line">229</span><br><span class="line">230</span><br><span class="line">231</span><br><span class="line">232</span><br><span class="line">233</span><br><span class="line">234</span><br><span class="line">235</span><br><span class="line">236</span><br><span class="line">237</span><br><span class="line">238</span><br><span class="line">239</span><br><span class="line">240</span><br><span class="line">241</span><br><span class="line">242</span><br><span class="line">243</span><br><span class="line">244</span><br><span class="line">245</span><br><span class="line">246</span><br><span class="line">247</span><br><span class="line">248</span><br><span class="line">249</span><br><span class="line">250</span><br><span class="line">251</span><br><span class="line">252</span><br><span class="line">253</span><br><span class="line">254</span><br><span class="line">255</span><br><span class="line">256</span><br><span class="line">257</span><br><span class="line">258</span><br><span class="line">259</span><br><span class="line">260</span><br><span class="line">261</span><br><span class="line">262</span><br><span class="line">263</span><br><span class="line">264</span><br><span class="line">265</span><br><span class="line">266</span><br><span class="line">267</span><br><span class="line">268</span><br><span class="line">269</span><br><span class="line">270</span><br><span class="line">271</span><br><span class="line">272</span><br><span class="line">273</span><br><span class="line">274</span><br><span class="line">275</span><br><span class="line">276</span><br><span class="line">277</span><br><span class="line">278</span><br><span class="line">279</span><br><span class="line">280</span><br><span class="line">281</span><br><span class="line">282</span><br><span class="line">283</span><br><span class="line">284</span><br><span class="line">285</span><br><span class="line">286</span><br><span class="line">287</span><br><span class="line">288</span><br><span class="line">289</span><br><span class="line">290</span><br><span class="line">291</span><br><span class="line">292</span><br><span class="line">293</span><br><span class="line">294</span><br><span class="line">295</span><br><span class="line">296</span><br><span class="line">297</span><br><span class="line">298</span><br><span class="line">299</span><br><span class="line">300</span><br><span class="line">301</span><br><span class="line">302</span><br><span class="line">303</span><br><span class="line">304</span><br><span class="line">305</span><br><span class="line">306</span><br><span class="line">307</span><br><span class="line">308</span><br><span class="line">309</span><br><span class="line">310</span><br><span class="line">311</span><br><span class="line">312</span><br><span class="line">313</span><br><span class="line">314</span><br><span class="line">315</span><br><span class="line">316</span><br><span class="line">317</span><br><span class="line">318</span><br><span class="line">319</span><br><span class="line">320</span><br><span class="line">321</span><br><span class="line">322</span><br><span class="line">323</span><br><span class="line">324</span><br><span class="line">325</span><br><span class="line">326</span><br><span class="line">327</span><br><span class="line">328</span><br><span class="line">329</span><br><span class="line">330</span><br><span class="line">331</span><br><span class="line">332</span><br><span class="line">333</span><br><span class="line">334</span><br><span class="line">335</span><br><span class="line">336</span><br><span class="line">337</span><br><span class="line">338</span><br><span class="line">339</span><br><span class="line">340</span><br><span class="line">341</span><br><span class="line">342</span><br><span class="line">343</span><br><span class="line">344</span><br><span class="line">345</span><br><span class="line">346</span><br><span class="line">347</span><br><span class="line">348</span><br><span class="line">349</span><br><span class="line">350</span><br><span class="line">351</span><br><span class="line">352</span><br><span class="line">353</span><br><span class="line">354</span><br><span class="line">355</span><br><span class="line">356</span><br><span class="line">357</span><br><span class="line">358</span><br><span class="line">359</span><br><span class="line">360</span><br><span class="line">361</span><br><span class="line">362</span><br><span class="line">363</span><br><span class="line">364</span><br><span class="line">365</span><br><span class="line">366</span><br><span class="line">367</span><br><span class="line">368</span><br><span class="line">369</span><br><span class="line">370</span><br><span class="line">371</span><br><span class="line">372</span><br><span class="line">373</span><br><span class="line">374</span><br><span class="line">375</span><br><span class="line">376</span><br><span class="line">377</span><br><span class="line">378</span><br><span class="line">379</span><br><span class="line">380</span><br><span class="line">381</span><br><span class="line">382</span><br><span class="line">383</span><br><span class="line">384</span><br><span class="line">385</span><br><span class="line">386</span><br><span class="line">387</span><br><span class="line">388</span><br></pre></td><td class="code"><pre><span class="line"><span class="comment">#!/usr/bin/python</span></span><br><span class="line"><span class="comment"># -*- coding: UTF-8 -*-</span></span><br><span class="line"><span class="keyword">import</span> prettytable <span class="keyword">as</span> pt</span><br><span class="line"><span class="keyword">import</span> sys</span><br><span class="line"><span class="keyword">import</span> string</span><br><span class="line"><span class="keyword">import</span> numpy</span><br><span class="line"><span class="keyword">import</span> array</span><br><span class="line"><span class="keyword">import</span> re</span><br><span class="line"></span><br><span class="line">sys.setrecursionlimit(<span class="number">1000000</span>)</span><br><span class="line"></span><br><span class="line"><span class="class"><span class="keyword">class</span> <span class="title">tc3</span><span class="params">(object)</span>:</span></span><br><span class="line"></span><br><span class="line">    __dic_formula=&#123;&#125; <span class="comment">#产生式的字典</span></span><br><span class="line">    __terSymbol=[<span class="string">'#'</span>] <span class="comment">#终结符号</span></span><br><span class="line">    __non_ter=[] <span class="comment">#非终结符号</span></span><br><span class="line">    __firstVT=&#123;&#125; <span class="comment">#firstvt集合</span></span><br><span class="line">    __lastVT=&#123;&#125; <span class="comment">#lastvt集合</span></span><br><span class="line">    __startsign=<span class="string">''</span></span><br><span class="line">    __emptysign=<span class="string">'$'</span> <span class="comment">#设置空的标识符</span></span><br><span class="line">    __anatable=[]</span><br><span class="line">    tb=pt.PrettyTable()</span><br><span class="line">    __tablem=&#123;&#125; <span class="comment">#用于存放预测分析数据的字典，其结构是</span></span><br><span class="line">    <span class="comment"># __tablem=&#123;终结符:[[上级非终结符,产生式],[]]&#125;</span></span><br><span class="line">    incount=<span class="number">0</span></span><br><span class="line">    __readtxt=[]</span><br><span class="line">    __yxjtable=numpy.array([]) <span class="comment">#优先级表</span></span><br><span class="line">    __chuan=<span class="string">""</span> <span class="comment">#读取的文本</span></span><br><span class="line">    __intxt=<span class="string">""</span></span><br><span class="line"></span><br><span class="line"></span><br><span class="line">    <span class="function"><span class="keyword">def</span> <span class="title">__init__</span><span class="params">(self)</span>:</span></span><br><span class="line">        print(<span class="string">"-------实验二-预测分析算法的设计与实现---------"</span>)</span><br><span class="line">        print(<span class="string">"作者：王政乔 20160520126"</span>)</span><br><span class="line">        <span class="keyword">pass</span></span><br><span class="line">    </span><br><span class="line">    <span class="function"><span class="keyword">def</span> <span class="title">insert_wf</span><span class="params">(self,filepath)</span>:</span></span><br><span class="line">        <span class="comment">#输入文法</span></span><br><span class="line">        fileread=open(filepath,mode=<span class="string">'r'</span>)</span><br><span class="line">        filereadtxt=fileread.readlines()</span><br><span class="line">        <span class="keyword">for</span> i <span class="keyword">in</span> range(<span class="number">0</span>,len(filereadtxt)<span class="number">-1</span>):</span><br><span class="line">            filereadtxt[i]=filereadtxt[i].rstrip(<span class="string">'\n'</span>) <span class="comment">#去掉右侧的\n符号</span></span><br><span class="line">        print(<span class="string">"----文本内容----"</span>)</span><br><span class="line">        print(filereadtxt)</span><br><span class="line">        self.__readtxt=filereadtxt</span><br><span class="line">        self.__startsign=filereadtxt[<span class="number">0</span>][<span class="number">0</span>]</span><br><span class="line">        <span class="keyword">for</span> i <span class="keyword">in</span> range(<span class="number">0</span>,len(filereadtxt)):</span><br><span class="line">            flagindex=filereadtxt[i].find(<span class="string">"-&gt;"</span>) <span class="comment">#从左到右找到第一个-&gt;符号</span></span><br><span class="line">            <span class="keyword">if</span> flagindex&gt;<span class="number">3</span>:</span><br><span class="line">                <span class="comment">#-&gt;符号太靠右了，说明一定有问题</span></span><br><span class="line">                print(<span class="string">"格式错误"</span>)</span><br><span class="line">            <span class="comment">#开始进行分割操作</span></span><br><span class="line">            <span class="comment">#print(filereadtxt[i][flagindex+2:]) #这个是把左侧内容清除掉后的内容</span></span><br><span class="line">            strright=filereadtxt[i][flagindex+<span class="number">2</span>:]</span><br><span class="line">            tdf=[]</span><br><span class="line">            tdf=strright.split(<span class="string">'|'</span>)</span><br><span class="line">            <span class="comment">#print(tdf)</span></span><br><span class="line">            <span class="keyword">if</span> filereadtxt[i][flagindex<span class="number">-1</span>] <span class="keyword">in</span> self.__dic_formula:</span><br><span class="line">                <span class="comment">#如果产生式的字典里已经存在这个非终结符</span></span><br><span class="line">                self.__dic_formula[filereadtxt[i][flagindex<span class="number">-1</span>]]+=tdf</span><br><span class="line">                <span class="keyword">pass</span></span><br><span class="line">            <span class="keyword">else</span>:</span><br><span class="line">                <span class="comment">#这是一个全新的非终结符</span></span><br><span class="line">                self.__dic_formula[filereadtxt[i][flagindex<span class="number">-1</span>]]=tdf</span><br><span class="line">                self.__non_ter.append(filereadtxt[i][flagindex<span class="number">-1</span>])</span><br><span class="line">        <span class="comment">#添加#S#的文法</span></span><br><span class="line">        self.__dic_formula[self.getNotHave()]=[<span class="string">'#'</span>+self.__non_ter[<span class="number">0</span>]+<span class="string">"#"</span>]</span><br><span class="line"></span><br><span class="line">        print(self.__readtxt)</span><br><span class="line">        print(self.__dic_formula)</span><br><span class="line">        print(self.__non_ter)</span><br><span class="line">        <span class="keyword">pass</span></span><br><span class="line">    </span><br><span class="line">    <span class="function"><span class="keyword">def</span> <span class="title">getNotHave</span><span class="params">(self)</span>:</span></span><br><span class="line">        <span class="comment">#会从大写字母表中，找没有出现过的关键字并返回</span></span><br><span class="line">        <span class="keyword">for</span> i <span class="keyword">in</span> string.ascii_uppercase[:]:</span><br><span class="line">            <span class="keyword">if</span> i <span class="keyword">not</span> <span class="keyword">in</span> self.__dic_formula:</span><br><span class="line">                <span class="comment">#不存在这个非终结符</span></span><br><span class="line">                <span class="keyword">return</span> i</span><br><span class="line">        </span><br><span class="line">        <span class="keyword">return</span> <span class="string">'!'</span></span><br><span class="line">    </span><br><span class="line">    </span><br><span class="line">    <span class="function"><span class="keyword">def</span> <span class="title">setterSymbol</span><span class="params">(self)</span>:</span></span><br><span class="line">        <span class="comment">#添加非终结符</span></span><br><span class="line">        <span class="keyword">for</span> key <span class="keyword">in</span> self.__dic_formula:</span><br><span class="line">            <span class="keyword">for</span> i <span class="keyword">in</span> range(<span class="number">0</span>,len(self.__dic_formula[key])):</span><br><span class="line">                <span class="keyword">for</span> j <span class="keyword">in</span> range(<span class="number">0</span>,len(self.__dic_formula[key][i])):</span><br><span class="line">                    <span class="keyword">if</span> self.__dic_formula[key][i][j] <span class="keyword">not</span> <span class="keyword">in</span> self.__non_ter:</span><br><span class="line">                        self.__terSymbol.append(self.__dic_formula[key][i][j])</span><br><span class="line">        self.__terSymbol=list(set(self.__terSymbol))</span><br><span class="line">        self.__terSymbol.sort()</span><br><span class="line">        print(self.__terSymbol)</span><br><span class="line">        <span class="keyword">pass</span></span><br><span class="line">    </span><br><span class="line">    <span class="function"><span class="keyword">def</span> <span class="title">setterSymbol_fromtxt</span><span class="params">(self)</span>:</span></span><br><span class="line">        <span class="comment">#从字符串获得终结符</span></span><br><span class="line">        <span class="keyword">for</span> temptxt <span class="keyword">in</span> self.__readtxt:</span><br><span class="line">            startindex=temptxt.index(<span class="string">"-&gt;"</span>)</span><br><span class="line">            <span class="keyword">for</span> i <span class="keyword">in</span> range(startindex+<span class="number">2</span>,len(temptxt)):</span><br><span class="line">                <span class="keyword">if</span> temptxt[i] <span class="keyword">not</span> <span class="keyword">in</span> self.__non_ter <span class="keyword">and</span> temptxt[i] !=<span class="string">"|"</span>:</span><br><span class="line">                    <span class="keyword">if</span> temptxt[i] <span class="keyword">not</span> <span class="keyword">in</span> self.__terSymbol:</span><br><span class="line">                        self.__terSymbol.append(temptxt[i])</span><br><span class="line">        self.__terSymbol.sort()</span><br><span class="line">        print(self.__terSymbol)</span><br><span class="line">        <span class="keyword">pass</span></span><br><span class="line">    </span><br><span class="line"></span><br><span class="line">    <span class="function"><span class="keyword">def</span> <span class="title">getfirstvt</span><span class="params">(self)</span>:</span></span><br><span class="line">        <span class="comment">#获取firstvt</span></span><br><span class="line">        <span class="keyword">for</span> dic_item <span class="keyword">in</span> self.__dic_formula:</span><br><span class="line">            self.getfirstVT_withdicitem(dic_item)</span><br><span class="line">        print(<span class="string">"FirstVT:"</span>,self.__firstVT)</span><br><span class="line">                    </span><br><span class="line">        <span class="keyword">pass</span></span><br><span class="line">    </span><br><span class="line">    <span class="function"><span class="keyword">def</span> <span class="title">getfirstVT_withdicitem</span><span class="params">(self,dic_item)</span>:</span></span><br><span class="line">        <span class="comment">#print("step")</span></span><br><span class="line">        <span class="keyword">for</span> list_item <span class="keyword">in</span> self.__dic_formula[dic_item]:</span><br><span class="line">            <span class="keyword">if</span> list_item[<span class="number">0</span>] <span class="keyword">in</span> self.__non_ter:</span><br><span class="line">                <span class="keyword">if</span> list_item[<span class="number">0</span>]!=dic_item:</span><br><span class="line">                    self.getfirstVT_withdicitem(list_item[<span class="number">0</span>])</span><br><span class="line">                    </span><br><span class="line">                templist=[]</span><br><span class="line">                <span class="keyword">if</span> dic_item <span class="keyword">not</span> <span class="keyword">in</span> self.__firstVT:</span><br><span class="line">                    self.__firstVT[dic_item]=[]</span><br><span class="line">                <span class="keyword">else</span>:</span><br><span class="line">                    templist=self.__firstVT[dic_item]</span><br><span class="line">                <span class="keyword">if</span> len(list_item)&gt;=<span class="number">2</span> <span class="keyword">and</span> list_item[<span class="number">1</span>] <span class="keyword">in</span> self.__terSymbol:</span><br><span class="line">                    </span><br><span class="line">                    <span class="keyword">if</span> dic_item <span class="keyword">in</span> self.__firstVT:</span><br><span class="line">                        templist=self.__firstVT[dic_item]</span><br><span class="line">                    <span class="comment">#if list_item[1] not in templist:</span></span><br><span class="line">                    templist.append(list_item[<span class="number">1</span>])</span><br><span class="line">                    <span class="comment">#print(dic_item,list_item[1],templist)</span></span><br><span class="line">                </span><br><span class="line">                self.__firstVT[dic_item]=templist + self.__firstVT[list_item[<span class="number">0</span>]]</span><br><span class="line">                self.__firstVT[dic_item]=list(set(self.__firstVT[dic_item]))</span><br><span class="line">                <span class="comment">#print(self.__firstVT)</span></span><br><span class="line">            <span class="keyword">else</span>:</span><br><span class="line">                <span class="comment">#第一位是终结符</span></span><br><span class="line">                templist=[]</span><br><span class="line">                <span class="keyword">if</span> dic_item <span class="keyword">in</span> self.__firstVT:</span><br><span class="line">                    templist=self.__firstVT[dic_item]</span><br><span class="line">                <span class="keyword">if</span> list_item[<span class="number">0</span>] <span class="keyword">not</span> <span class="keyword">in</span> templist:</span><br><span class="line">                    templist.append(list_item[<span class="number">0</span>])</span><br><span class="line">                self.__firstVT[dic_item]=templist</span><br><span class="line">    </span><br><span class="line">    <span class="function"><span class="keyword">def</span> <span class="title">getlastvt</span><span class="params">(self)</span>:</span></span><br><span class="line">        <span class="comment">#print("-----------lastvt")</span></span><br><span class="line">        <span class="keyword">for</span> dic_item <span class="keyword">in</span> self.__dic_formula:</span><br><span class="line">            self.getlastVT_withdicitem(dic_item,<span class="number">0</span>)</span><br><span class="line">        </span><br><span class="line">        <span class="keyword">for</span> i <span class="keyword">in</span> range(<span class="number">0</span>,len(self.__non_ter)<span class="number">-1</span>):</span><br><span class="line">            <span class="keyword">for</span> dic_item <span class="keyword">in</span> self.__lastVT:</span><br><span class="line">                <span class="keyword">for</span> list_item <span class="keyword">in</span> self.__lastVT[dic_item]:</span><br><span class="line">                    </span><br><span class="line">                    <span class="keyword">if</span> list_item <span class="keyword">in</span> self.__non_ter:</span><br><span class="line">                        <span class="comment">#如果是非终结符</span></span><br><span class="line">                        <span class="comment">#print(list_item," non ",self.__lastVT[list_item])</span></span><br><span class="line">                        templast=[]</span><br><span class="line">                        templast=self.__lastVT[dic_item]</span><br><span class="line">                        templast.remove(list_item)</span><br><span class="line">                        templast+=self.__lastVT[list_item]</span><br><span class="line">                        self.__lastVT[dic_item]=templast</span><br><span class="line">        print(<span class="string">"LastVT:"</span>,self.__lastVT)</span><br><span class="line">        <span class="keyword">pass</span></span><br><span class="line">    </span><br><span class="line">    <span class="function"><span class="keyword">def</span> <span class="title">getlastVT_withdicitem</span><span class="params">(self,dic_item,deeplevel)</span>:</span></span><br><span class="line"></span><br><span class="line">        <span class="keyword">for</span> list_item <span class="keyword">in</span> self.__dic_formula[dic_item]:</span><br><span class="line">            <span class="comment">#print(list_item[-1])</span></span><br><span class="line">            <span class="keyword">if</span> list_item[<span class="number">-1</span>] <span class="keyword">in</span> self.__non_ter:</span><br><span class="line">                <span class="comment">#最后一位非终结符</span></span><br><span class="line">                <span class="comment">#print(dic_item,list_item[-1],list_item[-2])</span></span><br><span class="line">                <span class="keyword">if</span> dic_item!=list_item[<span class="number">-1</span>]:</span><br><span class="line">                    <span class="comment">#说明</span></span><br><span class="line">                    self.getlastVT_withdicitem(list_item[<span class="number">-1</span>],deeplevel+<span class="number">1</span>)</span><br><span class="line">                templist=[]</span><br><span class="line">                <span class="keyword">if</span> dic_item <span class="keyword">not</span> <span class="keyword">in</span> self.__lastVT:</span><br><span class="line">                    self.__lastVT[dic_item]=[]</span><br><span class="line">                <span class="keyword">else</span>:</span><br><span class="line">                    templist=self.__lastVT[dic_item]</span><br><span class="line">                </span><br><span class="line">                <span class="keyword">if</span> len(list_item)&gt;=<span class="number">2</span> <span class="keyword">and</span> list_item[<span class="number">-2</span>] <span class="keyword">in</span> self.__terSymbol:</span><br><span class="line">                    </span><br><span class="line">                    <span class="keyword">if</span> dic_item <span class="keyword">in</span> self.__lastVT:</span><br><span class="line">                        templist=self.__lastVT[dic_item]</span><br><span class="line">                    <span class="keyword">if</span> list_item[<span class="number">-2</span>] <span class="keyword">not</span> <span class="keyword">in</span> templist:</span><br><span class="line">                        templist.append(list_item[<span class="number">-2</span>])</span><br><span class="line">                    <span class="comment">#print("last-&gt;",dic_item,list_item[-2],templist)</span></span><br><span class="line">                self.__lastVT[dic_item]=templist+self.__lastVT[list_item[<span class="number">-1</span>]]</span><br><span class="line">                self.__lastVT[dic_item]=list(set(self.__lastVT[dic_item]))</span><br><span class="line">            <span class="keyword">else</span>:</span><br><span class="line">                <span class="comment">#print(dic_item,list_item[-1])</span></span><br><span class="line">                <span class="comment">#最后一位是终结符</span></span><br><span class="line">                templist=[]</span><br><span class="line">                <span class="keyword">if</span> dic_item <span class="keyword">in</span> self.__lastVT:</span><br><span class="line">                    templist=self.__lastVT[dic_item]</span><br><span class="line">                <span class="keyword">if</span> list_item[<span class="number">-1</span>] <span class="keyword">not</span> <span class="keyword">in</span> templist:</span><br><span class="line">                    templist.append(list_item[<span class="number">-1</span>])</span><br><span class="line">                self.__lastVT[dic_item]=templist</span><br><span class="line"></span><br><span class="line">    <span class="function"><span class="keyword">def</span> <span class="title">getmatch</span><span class="params">(self,instring)</span>:</span></span><br><span class="line">        nonter=<span class="string">""</span></span><br><span class="line">        <span class="keyword">for</span> non <span class="keyword">in</span> self.__non_ter:</span><br><span class="line">            nonter=nonter + <span class="string">"|"</span> + non</span><br><span class="line">        nonter=<span class="string">"["</span> + nonter[<span class="number">1</span>:] + <span class="string">"]"</span></span><br><span class="line">        symter=<span class="string">""</span></span><br><span class="line">        <span class="keyword">for</span> tym <span class="keyword">in</span> self.__terSymbol:</span><br><span class="line">            symter=symter + <span class="string">"|"</span> + tym</span><br><span class="line">        symter=<span class="string">"["</span> + symter[<span class="number">1</span>:] +<span class="string">"]"</span></span><br><span class="line">        <span class="comment">#print(nonter," ",symter)</span></span><br><span class="line">        <span class="comment">#print("-&gt;",instring) </span></span><br><span class="line">        self.getmatch_equl(instring,nonter,symter)</span><br><span class="line">        self.getmatch_slower(instring,nonter,symter)</span><br><span class="line">        self.getmatch_quicker(instring,nonter,symter)</span><br><span class="line">        <span class="keyword">pass</span></span><br><span class="line">    </span><br><span class="line">    <span class="function"><span class="keyword">def</span> <span class="title">getmatch_start</span><span class="params">(self)</span>:</span></span><br><span class="line">        <span class="comment">#这个是专门给第一个文法设定的</span></span><br><span class="line">        startnon=self.__non_ter[<span class="number">0</span>]</span><br><span class="line">        <span class="comment"># #&lt;FirstVT(E)</span></span><br><span class="line">        <span class="keyword">for</span> fvt_item <span class="keyword">in</span> self.__firstVT[startnon]:</span><br><span class="line">            self.settableat(self.__terSymbol.index(<span class="string">'#'</span>),self.__terSymbol.index(fvt_item),<span class="string">'&lt;'</span>)</span><br><span class="line">        <span class="keyword">for</span> lvt_item <span class="keyword">in</span> self.__lastVT[startnon]:</span><br><span class="line">            self.settableat(self.__terSymbol.index(lvt_item),self.__terSymbol.index(<span class="string">'#'</span>),<span class="string">'&gt;'</span>)</span><br><span class="line">        <span class="comment"># LastVT(E)&gt;#</span></span><br><span class="line">        <span class="keyword">pass</span></span><br><span class="line">    </span><br><span class="line">    <span class="function"><span class="keyword">def</span> <span class="title">getmatch_equl</span><span class="params">(self,instring,nonter,symter)</span>:</span></span><br><span class="line">        pattern=re.compile(<span class="string">r''</span>+symter + nonter + symter)</span><br><span class="line">        result=pattern.findall(instring)  <span class="comment">#匹配aQa型</span></span><br><span class="line">        <span class="keyword">if</span> result!=[]:</span><br><span class="line">            <span class="comment">#print("aQa-&gt;(=)",result)</span></span><br><span class="line">            <span class="comment">#有结果</span></span><br><span class="line">            <span class="keyword">for</span> resitem <span class="keyword">in</span> result:</span><br><span class="line">                <span class="comment">#print(resitem[0],"=",resitem[-1])</span></span><br><span class="line">                self.settableat(self.__terSymbol.index(resitem[<span class="number">0</span>]),self.__terSymbol.index(resitem[<span class="number">-1</span>]),<span class="string">'='</span>)</span><br><span class="line">        pattern=re.compile(<span class="string">r''</span>+symter + symter)</span><br><span class="line">        result=pattern.findall(instring)  <span class="comment">#匹配aa型</span></span><br><span class="line">        <span class="keyword">if</span> result!=[]:</span><br><span class="line">            <span class="comment">#print("aa-&gt;(=)",result)</span></span><br><span class="line">            <span class="comment">#有结果</span></span><br><span class="line">            <span class="keyword">for</span> resitem <span class="keyword">in</span> result:</span><br><span class="line">                <span class="comment">#print(resitem[0],"=",resitem[-1])</span></span><br><span class="line">                self.settableat(self.__terSymbol.index(resitem[<span class="number">0</span>]),self.__terSymbol.index(resitem[<span class="number">1</span>]),<span class="string">'='</span>)</span><br><span class="line"></span><br><span class="line">        </span><br><span class="line">        <span class="keyword">pass</span></span><br><span class="line">    </span><br><span class="line">    <span class="function"><span class="keyword">def</span> <span class="title">getmatch_quicker</span><span class="params">(self,instring,nonter,symter)</span>:</span></span><br><span class="line">        <span class="comment">#优先级高于</span></span><br><span class="line">        pattern=re.compile(<span class="string">r''</span>+nonter+symter)</span><br><span class="line">        result=pattern.findall(instring) <span class="comment">#匹配aQ型</span></span><br><span class="line">        <span class="keyword">if</span> result!=[]:</span><br><span class="line">            <span class="comment">#print("Qa-&gt;(&gt;)",result)</span></span><br><span class="line">            <span class="keyword">for</span> resitem <span class="keyword">in</span> result:</span><br><span class="line">                <span class="keyword">for</span> lasitem <span class="keyword">in</span> self.__lastVT[resitem[<span class="number">0</span>]]:</span><br><span class="line">                    <span class="comment">#print(lasitem,"&gt;",resitem[1])</span></span><br><span class="line">                    self.settableat(self.__terSymbol.index(lasitem),self.__terSymbol.index(resitem[<span class="number">1</span>]),<span class="string">"&gt;"</span>)</span><br><span class="line">        </span><br><span class="line">        <span class="keyword">pass</span></span><br><span class="line">    </span><br><span class="line">    <span class="function"><span class="keyword">def</span> <span class="title">getmatch_slower</span><span class="params">(self,instring,nonter,symter)</span>:</span></span><br><span class="line">        <span class="comment">#优先级低于</span></span><br><span class="line">        pattern=re.compile(<span class="string">r''</span>+symter+nonter)</span><br><span class="line">        result=pattern.findall(instring) <span class="comment">#匹配aQ型</span></span><br><span class="line">        <span class="keyword">if</span> result!=[]:</span><br><span class="line">            <span class="comment">#print("aQ-&gt;(&lt;)",result)</span></span><br><span class="line">            <span class="keyword">for</span> resitem <span class="keyword">in</span> result:</span><br><span class="line">                <span class="keyword">for</span> lasitem <span class="keyword">in</span> self.__firstVT[resitem[<span class="number">-1</span>]]:</span><br><span class="line">                    <span class="comment">#print(resitem[0],"&lt;",lasitem)</span></span><br><span class="line">                    self.settableat(self.__terSymbol.index(resitem[<span class="number">0</span>]),self.__terSymbol.index(lasitem),<span class="string">"&lt;"</span>)</span><br><span class="line">        </span><br><span class="line">        <span class="keyword">pass</span></span><br><span class="line">    </span><br><span class="line">    <span class="function"><span class="keyword">def</span> <span class="title">settableat</span><span class="params">(self,i,j,value)</span>:</span></span><br><span class="line">        <span class="comment">#i为行，j为列，value为值</span></span><br><span class="line">        <span class="keyword">if</span> self.__yxjtable[i,j]==<span class="string">'?'</span>:</span><br><span class="line">            self.__yxjtable[i,j]=value</span><br><span class="line">        <span class="keyword">pass</span></span><br><span class="line"></span><br><span class="line">    <span class="function"><span class="keyword">def</span> <span class="title">getindextable</span><span class="params">(self)</span>:</span></span><br><span class="line">        <span class="comment">#获取优先级表</span></span><br><span class="line">        <span class="comment">#优先级表初始化</span></span><br><span class="line">        self.__yxjtable=numpy.full((len(self.__terSymbol),len(self.__terSymbol)),<span class="string">"?"</span>)</span><br><span class="line">        self.getmatch_start()</span><br><span class="line">        <span class="keyword">for</span> dic_item <span class="keyword">in</span> self.__dic_formula:</span><br><span class="line">            <span class="keyword">for</span> list_item <span class="keyword">in</span> self.__dic_formula[dic_item]:</span><br><span class="line">                self.getmatch(list_item)</span><br><span class="line">        <span class="comment">#print(self.__yxjtable)</span></span><br><span class="line"></span><br><span class="line">        print(<span class="string">"显示为优先级表格"</span>)</span><br><span class="line">        self.tb=pt.PrettyTable()</span><br><span class="line">        li=self.__yxjtable.tolist()</span><br><span class="line">        self.tb.field_names=[<span class="string">'word'</span>]+self.__terSymbol </span><br><span class="line">        <span class="comment">#print(len(li))</span></span><br><span class="line">        <span class="keyword">for</span> i <span class="keyword">in</span> range(<span class="number">0</span>,len(li)):</span><br><span class="line">            self.tb.add_row([self.__terSymbol[i]]+li[i])</span><br><span class="line">        print(self.tb)</span><br><span class="line">        <span class="keyword">pass</span></span><br><span class="line"></span><br><span class="line">    <span class="function"><span class="keyword">def</span> <span class="title">printall</span><span class="params">(self)</span>:</span></span><br><span class="line">        print(<span class="string">"-------结果--------"</span>)</span><br><span class="line">        print(<span class="string">"--产生式："</span>)</span><br><span class="line">        print(self.__dic_formula)</span><br><span class="line">        print(<span class="string">"--终结符："</span>)</span><br><span class="line">        print(self.__terSymbol)</span><br><span class="line">        print(<span class="string">"--非终结符："</span>)</span><br><span class="line">        print(self.__non_ter)</span><br><span class="line">        </span><br><span class="line">    <span class="function"><span class="keyword">def</span> <span class="title">readletters</span><span class="params">(self,filepath)</span>:</span></span><br><span class="line">        <span class="comment">#从文本文件读取数据</span></span><br><span class="line">        print(<span class="string">"文本中的句子是："</span>)</span><br><span class="line">        fileread=open(filepath,mode=<span class="string">'r'</span>)</span><br><span class="line">        filereadtxt=fileread.read()</span><br><span class="line">        print(filereadtxt)</span><br><span class="line">        self.__intxt=filereadtxt</span><br><span class="line">        <span class="keyword">pass</span></span><br><span class="line">    </span><br><span class="line">    <span class="function"><span class="keyword">def</span> <span class="title">findhigherlevel</span><span class="params">(self,righttext)</span>:</span></span><br><span class="line">        <span class="comment">#找上一级的说法,返回[a,b]表示要替换掉的位,c表示替换的内容</span></span><br><span class="line">        <span class="keyword">for</span> i <span class="keyword">in</span> range(len(righttext)<span class="number">-1</span>,<span class="number">0</span>,<span class="number">-1</span>):</span><br><span class="line">            <span class="keyword">for</span> dic_item <span class="keyword">in</span> self.__dic_formula:</span><br><span class="line">                <span class="keyword">for</span> list_item <span class="keyword">in</span> self.__dic_formula[dic_item]:</span><br><span class="line">                    getindex=righttext[i:].find(list_item)</span><br><span class="line">                    <span class="keyword">if</span> getindex!=<span class="number">-1</span>:</span><br><span class="line">                        <span class="comment">#找到了匹配项</span></span><br><span class="line">                        <span class="keyword">return</span> [getindex+i,len(list_item)],dic_item</span><br><span class="line">        <span class="keyword">return</span> [<span class="number">-1</span>,<span class="number">-1</span>],<span class="string">'null'</span></span><br><span class="line">    </span><br><span class="line">    <span class="function"><span class="keyword">def</span> <span class="title">getindexbefore</span><span class="params">(self,lefttext)</span>:</span></span><br><span class="line">        <span class="comment">#从左侧的栈中，从右至左找到第一个终结符并返回</span></span><br><span class="line">        </span><br><span class="line">        <span class="keyword">for</span> i <span class="keyword">in</span> range(len(lefttext)<span class="number">-1</span>,<span class="number">0</span>,<span class="number">-1</span>):</span><br><span class="line">            <span class="keyword">if</span> lefttext[i] <span class="keyword">in</span> self.__terSymbol:</span><br><span class="line">                <span class="keyword">return</span> lefttext[i]</span><br><span class="line"></span><br><span class="line">        <span class="keyword">return</span> <span class="string">'#'</span></span><br><span class="line">    </span><br><span class="line">    <span class="function"><span class="keyword">def</span> <span class="title">readyxjtable</span><span class="params">(self,a,b)</span>:</span></span><br><span class="line">        <span class="keyword">return</span> self.__yxjtable[self.__terSymbol.index(a),self.__terSymbol.index(b)]</span><br><span class="line">    </span><br><span class="line">    <span class="function"><span class="keyword">def</span> <span class="title">redothetext</span><span class="params">(self)</span>:</span></span><br><span class="line"></span><br><span class="line">        self.tb=pt.PrettyTable()</span><br><span class="line">        self.tb.field_names=[<span class="string">'步骤'</span>,<span class="string">'栈'</span>,<span class="string">'优先关系'</span>,<span class="string">'当前符号'</span>,<span class="string">'剩余符号'</span>,<span class="string">'动作'</span>]</span><br><span class="line">        </span><br><span class="line">        count=<span class="number">0</span></span><br><span class="line">        left=[<span class="string">'#'</span>]</span><br><span class="line">        right=list(self.__intxt)+[<span class="string">'#'</span>]</span><br><span class="line">        self.tb.add_row([<span class="number">0</span>,<span class="string">''</span>.join(left),self.readyxjtable(self.getindexbefore(left),right[<span class="number">0</span>]),right[<span class="number">0</span>],<span class="string">''</span>.join(right),<span class="string">'准备'</span>])</span><br><span class="line">        <span class="keyword">while</span>(<span class="literal">True</span>):</span><br><span class="line">            count+=<span class="number">1</span></span><br><span class="line">            print(left,right,self.getindexbefore(left))</span><br><span class="line">            <span class="keyword">if</span> len(right)&gt;<span class="number">0</span>:</span><br><span class="line">                <span class="keyword">if</span> self.readyxjtable(self.getindexbefore(left),right[<span class="number">0</span>])==<span class="string">'&gt;'</span>:</span><br><span class="line">                    </span><br><span class="line">                    [start,end],value=self.findhigherlevel(<span class="string">''</span>.join(left))</span><br><span class="line">                    <span class="keyword">if</span> end!=<span class="number">-1</span>:</span><br><span class="line">                        left=left[:start] + [value]</span><br><span class="line">                        self.tb.add_row([count,<span class="string">''</span>.join(left),self.readyxjtable(self.getindexbefore(left),right[<span class="number">0</span>]),right[<span class="number">0</span>],<span class="string">''</span>.join(right),<span class="string">'规约'</span>])</span><br><span class="line">                    print(left)</span><br><span class="line">                    <span class="comment">#说明要规约</span></span><br><span class="line">                    <span class="keyword">pass</span></span><br><span class="line">                <span class="keyword">elif</span> right==[<span class="string">'#'</span>]:</span><br><span class="line">                    <span class="comment">#已经完成移进，要进行左边的规约</span></span><br><span class="line">                    [start,end],value=self.findhigherlevel(<span class="string">''</span>.join(left))</span><br><span class="line">                    <span class="keyword">if</span> end!=<span class="number">-1</span>:</span><br><span class="line">                        left=left[:start] + [value]</span><br><span class="line">                    <span class="comment">#print(left)</span></span><br><span class="line">                <span class="keyword">else</span>:</span><br><span class="line">                    </span><br><span class="line">                    left.append(right.pop(<span class="number">0</span>)) </span><br><span class="line">                    self.tb.add_row([count,<span class="string">''</span>.join(left),self.readyxjtable(self.getindexbefore(left),right[<span class="number">0</span>]),right[<span class="number">0</span>],<span class="string">''</span>.join(right),<span class="string">'移进'</span>])</span><br><span class="line">                </span><br><span class="line"></span><br><span class="line">            <span class="keyword">if</span> left==[<span class="string">'#'</span>,self.__non_ter[<span class="number">0</span>]] <span class="keyword">and</span> right==[<span class="string">'#'</span>]:</span><br><span class="line">                self.tb.add_row([count,<span class="string">''</span>.join(left),<span class="string">''</span>,<span class="string">''</span>,<span class="string">''</span>.join(right),<span class="string">'完成'</span>])</span><br><span class="line">                <span class="keyword">break</span></span><br><span class="line"></span><br><span class="line"></span><br><span class="line"></span><br><span class="line">        print(self.tb)</span><br><span class="line"></span><br><span class="line"></span><br><span class="line">        <span class="keyword">pass</span></span><br></pre></td></tr></table></figure>

<p>之后可以在另一个文件里引用，就非常的简单</p>
<p>test3.py</p>
<figure class="highlight python"><table><tr><td class="gutter"><pre><span class="line">1</span><br><span class="line">2</span><br><span class="line">3</span><br><span class="line">4</span><br><span class="line">5</span><br><span class="line">6</span><br><span class="line">7</span><br><span class="line">8</span><br><span class="line">9</span><br><span class="line">10</span><br><span class="line">11</span><br><span class="line">12</span><br><span class="line">13</span><br><span class="line">14</span><br><span class="line">15</span><br><span class="line">16</span><br><span class="line">17</span><br><span class="line">18</span><br><span class="line">19</span><br><span class="line">20</span><br><span class="line">21</span><br><span class="line">22</span><br><span class="line">23</span><br></pre></td><td class="code"><pre><span class="line"><span class="comment">#!/usr/bin/python</span></span><br><span class="line"><span class="comment"># -*- coding: UTF-8 -*-</span></span><br><span class="line"><span class="keyword">import</span> tc3</span><br><span class="line"><span class="keyword">import</span> os</span><br><span class="line"></span><br><span class="line">print(<span class="string">"\033c"</span>) <span class="comment">#清屏</span></span><br><span class="line">x=tc3.tc3()</span><br><span class="line">x.insert_wf(<span class="string">"h1.txt"</span>)</span><br><span class="line">x.setterSymbol_fromtxt()</span><br><span class="line">x.setterSymbol()  <span class="comment">#已被抛弃</span></span><br><span class="line"><span class="comment">#此时已经完成终结符和非终结符的获取</span></span><br><span class="line"></span><br><span class="line"></span><br><span class="line"></span><br><span class="line"><span class="comment">#实验三</span></span><br><span class="line"></span><br><span class="line">x.getfirstvt()</span><br><span class="line">x.getlastvt()</span><br><span class="line"></span><br><span class="line">x.getindextable()</span><br><span class="line"></span><br><span class="line">x.readletters(<span class="string">"h2.txt"</span>)</span><br><span class="line">x.redothetext()</span><br></pre></td></tr></table></figure>

<p>在使用时，只需要</p>
<figure class="highlight bash"><table><tr><td class="gutter"><pre><span class="line">1</span><br></pre></td><td class="code"><pre><span class="line">python test3.py</span><br></pre></td></tr></table></figure>

<p>即可运行～，文法存放在h1.txt中，于同一目录下，格式如下：</p>
<figure class="highlight plain"><table><tr><td class="gutter"><pre><span class="line">1</span><br><span class="line">2</span><br><span class="line">3</span><br><span class="line">4</span><br></pre></td><td class="code"><pre><span class="line">E-&gt;E+T|T</span><br><span class="line">T-&gt;T*F|F</span><br><span class="line">F-&gt;P↑F|P</span><br><span class="line">P-&gt;(E)|i</span><br></pre></td></tr></table></figure>

<p>h2.txt存放输入串</p>
<figure class="highlight plain"><table><tr><td class="gutter"><pre><span class="line">1</span><br></pre></td><td class="code"><pre><span class="line">i*i+i↑i</span><br></pre></td></tr></table></figure>



<p>最后输出的结果如下：</p>
<figure class="highlight plain"><table><tr><td class="gutter"><pre><span class="line">1</span><br><span class="line">2</span><br><span class="line">3</span><br><span class="line">4</span><br><span class="line">5</span><br><span class="line">6</span><br><span class="line">7</span><br><span class="line">8</span><br><span class="line">9</span><br><span class="line">10</span><br><span class="line">11</span><br><span class="line">12</span><br><span class="line">13</span><br><span class="line">14</span><br><span class="line">15</span><br><span class="line">16</span><br><span class="line">17</span><br><span class="line">18</span><br><span class="line">19</span><br><span class="line">20</span><br><span class="line">21</span><br><span class="line">22</span><br><span class="line">23</span><br><span class="line">24</span><br><span class="line">25</span><br><span class="line">26</span><br><span class="line">27</span><br><span class="line">28</span><br><span class="line">29</span><br><span class="line">30</span><br><span class="line">31</span><br><span class="line">32</span><br><span class="line">33</span><br><span class="line">34</span><br><span class="line">35</span><br><span class="line">36</span><br><span class="line">37</span><br><span class="line">38</span><br><span class="line">39</span><br><span class="line">40</span><br><span class="line">41</span><br><span class="line">42</span><br><span class="line">43</span><br><span class="line">44</span><br><span class="line">45</span><br><span class="line">46</span><br><span class="line">47</span><br><span class="line">48</span><br><span class="line">49</span><br><span class="line">50</span><br><span class="line">51</span><br><span class="line">52</span><br><span class="line">53</span><br><span class="line">54</span><br><span class="line">55</span><br><span class="line">56</span><br><span class="line">57</span><br><span class="line">58</span><br><span class="line">59</span><br><span class="line">60</span><br><span class="line">61</span><br><span class="line">62</span><br><span class="line">63</span><br><span class="line">64</span><br><span class="line">65</span><br><span class="line">66</span><br><span class="line">67</span><br><span class="line">68</span><br><span class="line">69</span><br><span class="line">70</span><br><span class="line">71</span><br><span class="line">72</span><br><span class="line">73</span><br><span class="line">74</span><br><span class="line">75</span><br><span class="line">76</span><br><span class="line">77</span><br><span class="line">78</span><br><span class="line">79</span><br><span class="line">80</span><br><span class="line">81</span><br><span class="line">82</span><br><span class="line">83</span><br><span class="line">84</span><br><span class="line">85</span><br><span class="line">86</span><br><span class="line">87</span><br><span class="line">88</span><br><span class="line">89</span><br><span class="line">90</span><br><span class="line">91</span><br><span class="line">92</span><br><span class="line">93</span><br></pre></td><td class="code"><pre><span class="line"></span><br><span class="line">-------实验二-预测分析算法的设计与实现---------</span><br><span class="line">作者：王政乔 20160520126</span><br><span class="line">----文本内容----</span><br><span class="line">[&#39;E-&gt;E+T|T&#39;, &#39;T-&gt;T*F|F&#39;, &#39;F-&gt;P↑F|P&#39;, &#39;P-&gt;(E)|i&#39;]</span><br><span class="line">[&#39;E-&gt;E+T|T&#39;, &#39;T-&gt;T*F|F&#39;, &#39;F-&gt;P↑F|P&#39;, &#39;P-&gt;(E)|i&#39;]</span><br><span class="line">&#123;&#39;E&#39;: [&#39;E+T&#39;, &#39;T&#39;], &#39;T&#39;: [&#39;T*F&#39;, &#39;F&#39;], &#39;F&#39;: [&#39;P↑F&#39;, &#39;P&#39;], &#39;P&#39;: [&#39;(E)&#39;, &#39;i&#39;], &#39;A&#39;: [&#39;#E#&#39;]&#125;</span><br><span class="line">[&#39;E&#39;, &#39;T&#39;, &#39;F&#39;, &#39;P&#39;]</span><br><span class="line">[&#39;#&#39;, &#39;(&#39;, &#39;)&#39;, &#39;*&#39;, &#39;+&#39;, &#39;i&#39;, &#39;↑&#39;]</span><br><span class="line">[&#39;#&#39;, &#39;(&#39;, &#39;)&#39;, &#39;*&#39;, &#39;+&#39;, &#39;i&#39;, &#39;↑&#39;]</span><br><span class="line">FirstVT: &#123;&#39;E&#39;: [&#39;*&#39;, &#39;↑&#39;, &#39;+&#39;, &#39;i&#39;, &#39;(&#39;], &#39;T&#39;: [&#39;*&#39;, &#39;i&#39;, &#39;↑&#39;, &#39;(&#39;], &#39;P&#39;: [&#39;(&#39;, &#39;i&#39;], &#39;F&#39;: [&#39;i&#39;, &#39;↑&#39;, &#39;(&#39;], &#39;A&#39;: [&#39;#&#39;]&#125;</span><br><span class="line">LastVT: &#123;&#39;F&#39;: [&#39;i&#39;, &#39;↑&#39;, &#39;)&#39;], &#39;P&#39;: [&#39;)&#39;, &#39;i&#39;], &#39;T&#39;: [&#39;*&#39;, &#39;i&#39;, &#39;↑&#39;, &#39;)&#39;], &#39;E&#39;: [&#39;*&#39;, &#39;↑&#39;, &#39;+&#39;, &#39;i&#39;, &#39;)&#39;], &#39;A&#39;: [&#39;#&#39;]&#125;</span><br><span class="line">显示为优先级表格</span><br><span class="line">+------+---+---+---+---+---+---+---+</span><br><span class="line">| word | # | ( | ) | * | + | i | ↑ |</span><br><span class="line">+------+---+---+---+---+---+---+---+</span><br><span class="line">|  #   | &#x3D; | &lt; | ? | &lt; | &lt; | &lt; | &lt; |</span><br><span class="line">|  (   | ? | &lt; | &#x3D; | &lt; | &lt; | &lt; | &lt; |</span><br><span class="line">|  )   | &gt; | ? | &gt; | &gt; | &gt; | ? | &gt; |</span><br><span class="line">|  *   | &gt; | &lt; | &gt; | &gt; | &gt; | &lt; | &lt; |</span><br><span class="line">|  +   | &gt; | &lt; | &gt; | &lt; | &gt; | &lt; | &lt; |</span><br><span class="line">|  i   | &gt; | ? | &gt; | &gt; | &gt; | ? | &gt; |</span><br><span class="line">|  ↑   | &gt; | &lt; | &gt; | &gt; | &gt; | &lt; | &lt; |</span><br><span class="line">+------+---+---+---+---+---+---+---+</span><br><span class="line">文本中的句子是：</span><br><span class="line">i*i+i↑i</span><br><span class="line">[&#39;#&#39;] [&#39;i&#39;, &#39;*&#39;, &#39;i&#39;, &#39;+&#39;, &#39;i&#39;, &#39;↑&#39;, &#39;i&#39;, &#39;#&#39;] #</span><br><span class="line">[&#39;#&#39;, &#39;i&#39;] [&#39;*&#39;, &#39;i&#39;, &#39;+&#39;, &#39;i&#39;, &#39;↑&#39;, &#39;i&#39;, &#39;#&#39;] i</span><br><span class="line">[&#39;#&#39;, &#39;P&#39;]</span><br><span class="line">[&#39;#&#39;, &#39;P&#39;] [&#39;*&#39;, &#39;i&#39;, &#39;+&#39;, &#39;i&#39;, &#39;↑&#39;, &#39;i&#39;, &#39;#&#39;] #</span><br><span class="line">[&#39;#&#39;, &#39;P&#39;, &#39;*&#39;] [&#39;i&#39;, &#39;+&#39;, &#39;i&#39;, &#39;↑&#39;, &#39;i&#39;, &#39;#&#39;] *</span><br><span class="line">[&#39;#&#39;, &#39;P&#39;, &#39;*&#39;, &#39;i&#39;] [&#39;+&#39;, &#39;i&#39;, &#39;↑&#39;, &#39;i&#39;, &#39;#&#39;] i</span><br><span class="line">[&#39;#&#39;, &#39;P&#39;, &#39;*&#39;, &#39;P&#39;]</span><br><span class="line">[&#39;#&#39;, &#39;P&#39;, &#39;*&#39;, &#39;P&#39;] [&#39;+&#39;, &#39;i&#39;, &#39;↑&#39;, &#39;i&#39;, &#39;#&#39;] *</span><br><span class="line">[&#39;#&#39;, &#39;P&#39;, &#39;*&#39;, &#39;F&#39;]</span><br><span class="line">[&#39;#&#39;, &#39;P&#39;, &#39;*&#39;, &#39;F&#39;] [&#39;+&#39;, &#39;i&#39;, &#39;↑&#39;, &#39;i&#39;, &#39;#&#39;] *</span><br><span class="line">[&#39;#&#39;, &#39;P&#39;, &#39;*&#39;, &#39;T&#39;]</span><br><span class="line">[&#39;#&#39;, &#39;P&#39;, &#39;*&#39;, &#39;T&#39;] [&#39;+&#39;, &#39;i&#39;, &#39;↑&#39;, &#39;i&#39;, &#39;#&#39;] *</span><br><span class="line">[&#39;#&#39;, &#39;P&#39;, &#39;*&#39;, &#39;E&#39;]</span><br><span class="line">[&#39;#&#39;, &#39;P&#39;, &#39;*&#39;, &#39;E&#39;] [&#39;+&#39;, &#39;i&#39;, &#39;↑&#39;, &#39;i&#39;, &#39;#&#39;] *</span><br><span class="line">[&#39;#&#39;, &#39;F&#39;]</span><br><span class="line">[&#39;#&#39;, &#39;F&#39;] [&#39;+&#39;, &#39;i&#39;, &#39;↑&#39;, &#39;i&#39;, &#39;#&#39;] #</span><br><span class="line">[&#39;#&#39;, &#39;F&#39;, &#39;+&#39;] [&#39;i&#39;, &#39;↑&#39;, &#39;i&#39;, &#39;#&#39;] +</span><br><span class="line">[&#39;#&#39;, &#39;F&#39;, &#39;+&#39;, &#39;i&#39;] [&#39;↑&#39;, &#39;i&#39;, &#39;#&#39;] i</span><br><span class="line">[&#39;#&#39;, &#39;F&#39;, &#39;+&#39;, &#39;P&#39;]</span><br><span class="line">[&#39;#&#39;, &#39;F&#39;, &#39;+&#39;, &#39;P&#39;] [&#39;↑&#39;, &#39;i&#39;, &#39;#&#39;] +</span><br><span class="line">[&#39;#&#39;, &#39;F&#39;, &#39;+&#39;, &#39;P&#39;, &#39;↑&#39;] [&#39;i&#39;, &#39;#&#39;] ↑</span><br><span class="line">[&#39;#&#39;, &#39;F&#39;, &#39;+&#39;, &#39;P&#39;, &#39;↑&#39;, &#39;i&#39;] [&#39;#&#39;] i</span><br><span class="line">[&#39;#&#39;, &#39;F&#39;, &#39;+&#39;, &#39;P&#39;, &#39;↑&#39;, &#39;P&#39;]</span><br><span class="line">[&#39;#&#39;, &#39;F&#39;, &#39;+&#39;, &#39;P&#39;, &#39;↑&#39;, &#39;P&#39;] [&#39;#&#39;] ↑</span><br><span class="line">[&#39;#&#39;, &#39;F&#39;, &#39;+&#39;, &#39;P&#39;, &#39;↑&#39;, &#39;F&#39;]</span><br><span class="line">[&#39;#&#39;, &#39;F&#39;, &#39;+&#39;, &#39;P&#39;, &#39;↑&#39;, &#39;F&#39;] [&#39;#&#39;] ↑</span><br><span class="line">[&#39;#&#39;, &#39;F&#39;, &#39;+&#39;, &#39;P&#39;, &#39;↑&#39;, &#39;T&#39;]</span><br><span class="line">[&#39;#&#39;, &#39;F&#39;, &#39;+&#39;, &#39;P&#39;, &#39;↑&#39;, &#39;T&#39;] [&#39;#&#39;] ↑</span><br><span class="line">[&#39;#&#39;, &#39;F&#39;, &#39;+&#39;, &#39;P&#39;, &#39;↑&#39;, &#39;E&#39;]</span><br><span class="line">[&#39;#&#39;, &#39;F&#39;, &#39;+&#39;, &#39;P&#39;, &#39;↑&#39;, &#39;E&#39;] [&#39;#&#39;] ↑</span><br><span class="line">[&#39;#&#39;, &#39;F&#39;, &#39;+&#39;, &#39;F&#39;]</span><br><span class="line">[&#39;#&#39;, &#39;F&#39;, &#39;+&#39;, &#39;F&#39;] [&#39;#&#39;] +</span><br><span class="line">[&#39;#&#39;, &#39;F&#39;, &#39;+&#39;, &#39;T&#39;]</span><br><span class="line">[&#39;#&#39;, &#39;F&#39;, &#39;+&#39;, &#39;T&#39;] [&#39;#&#39;] +</span><br><span class="line">[&#39;#&#39;, &#39;F&#39;, &#39;+&#39;, &#39;E&#39;]</span><br><span class="line">[&#39;#&#39;, &#39;F&#39;, &#39;+&#39;, &#39;E&#39;] [&#39;#&#39;] +</span><br><span class="line">[&#39;#&#39;, &#39;T&#39;]</span><br><span class="line">[&#39;#&#39;, &#39;T&#39;] [&#39;#&#39;] #</span><br><span class="line">+------+--------+----------+----------+----------+------+</span><br><span class="line">| 步骤 |   栈   | 优先关系 | 当前符号 | 剩余符号 | 动作 |</span><br><span class="line">+------+--------+----------+----------+----------+------+</span><br><span class="line">|  0   |   #    |    &lt;     |    i     | i*i+i↑i# | 准备 |</span><br><span class="line">|  1   |   #i   |    &gt;     |    *     | *i+i↑i#  | 移进 |</span><br><span class="line">|  2   |   #P   |    &lt;     |    *     | *i+i↑i#  | 规约 |</span><br><span class="line">|  3   |  #P*   |    &lt;     |    i     |  i+i↑i#  | 移进 |</span><br><span class="line">|  4   |  #P*i  |    &gt;     |    +     |  +i↑i#   | 移进 |</span><br><span class="line">|  5   |  #P*P  |    &gt;     |    +     |  +i↑i#   | 规约 |</span><br><span class="line">|  6   |  #P*F  |    &gt;     |    +     |  +i↑i#   | 规约 |</span><br><span class="line">|  7   |  #P*T  |    &gt;     |    +     |  +i↑i#   | 规约 |</span><br><span class="line">|  8   |  #P*E  |    &gt;     |    +     |  +i↑i#   | 规约 |</span><br><span class="line">|  9   |   #F   |    &lt;     |    +     |  +i↑i#   | 规约 |</span><br><span class="line">|  10  |  #F+   |    &lt;     |    i     |   i↑i#   | 移进 |</span><br><span class="line">|  11  |  #F+i  |    &gt;     |    ↑     |   ↑i#    | 移进 |</span><br><span class="line">|  12  |  #F+P  |    &lt;     |    ↑     |   ↑i#    | 规约 |</span><br><span class="line">|  13  | #F+P↑  |    &lt;     |    i     |    i#    | 移进 |</span><br><span class="line">|  14  | #F+P↑i |    &gt;     |    #     |    #     | 移进 |</span><br><span class="line">|  15  | #F+P↑P |    &gt;     |    #     |    #     | 规约 |</span><br><span class="line">|  16  | #F+P↑F |    &gt;     |    #     |    #     | 规约 |</span><br><span class="line">|  17  | #F+P↑T |    &gt;     |    #     |    #     | 规约 |</span><br><span class="line">|  18  | #F+P↑E |    &gt;     |    #     |    #     | 规约 |</span><br><span class="line">|  19  |  #F+F  |    &gt;     |    #     |    #     | 规约 |</span><br><span class="line">|  20  |  #F+T  |    &gt;     |    #     |    #     | 规约 |</span><br><span class="line">|  21  |  #F+E  |    &gt;     |    #     |    #     | 规约 |</span><br><span class="line">|  22  |   #T   |    &#x3D;     |    #     |    #     | 规约 |</span><br><span class="line">|  23  |   #E   |          |          |    #     | 完成 |</span><br><span class="line">+------+--------+----------+----------+----------+------+</span><br><span class="line">joger@joger-PC:~&#x2F;Documents&#x2F;编译原理&#x2F;test3$</span><br></pre></td></tr></table></figure>

<p>emmmmmm，迷之规约过程，上面表头还没改，等算法改好了再说吧～</p>

            
        </div>
        
            <div style="text-align:left;font-size:14px;">
                <p style="text-align:center;color: #ccc;">-------------本文结束<i class="fas fa-eye"></i>感谢您的阅读-------------</p>
                
            </div>
            <ul class="post-copyright">
                <li class="post-copyright-license">
                    <strong>版权声明： </strong>
                    采用<a rel="license" href="http://creativecommons.org/licenses/by-nc-sa/2.5/cn/">知识共享署名2.5</a>许可。<a rel="license" href="http://creativecommons.org/licenses/by-nc-sa/2.5/cn/"><img alt="知识共享许可协议" style="border-width:0" src="https://i.creativecommons.org/l/by-nc-sa/2.5/cn/80x15.png" /></a>
                  </li>

                <li class="post-copyright-link">
                 <strong>本文作者：</strong>
                 王政乔
               </li>
       
               <li class="post-copyright-link">
                 <strong>本文标题：</strong>
                 编译原理实验三：算符优先算法实现(半成品)
               </li>
       
               <li class="post-copyright-link">
                 <strong>本文链接：</strong>
                 https://www.zhengqiao.wang/2018-12-06-编译原理实验三/
               </li>
       
               
             </ul>
        

        
        
        <div class="level is-size-7 is-uppercase">
            <div class="level-start">
                <div class="level-item">
                    <span class="is-size-6 has-text-grey has-mr-7">#</span>
                    <a class="has-link-grey -link" href="/tags/python/" rel="tag">python</a>, <a class="has-link-grey -link" href="/tags/%E4%BB%A3%E7%A0%81%E5%AD%98%E6%A1%A3/" rel="tag">代码存档</a>, <a class="has-link-grey -link" href="/tags/%E7%BC%96%E8%AF%91%E5%8E%9F%E7%90%86/" rel="tag">编译原理</a>
                </div>
            </div>
        </div>
        
        
        
        <div class="social-share"></div>
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/social-share.js@1.0.16/dist/css/share.min.css">
<script src="https://cdn.jsdelivr.net/npm/social-share.js@1.0.16/dist/js/social-share.min.js"></script>
        
    </div>
</div>



<div class="card">
    <div class="card-content">
        <h3 class="menu-label has-text-centered">喜欢这篇文章？打赏一下作者吧</h3>
        <div class="buttons is-centered">
            
                
<a class="button is-info donate">
    <span class="icon is-small">
        <i class="fab fa-alipay"></i>
    </span>
    <span>支付宝</span>
    <div class="qrcode"><img src="/images/%E6%94%AF%E4%BB%98%E5%AE%9D%E6%94%B6%E6%AC%BE%E7%A0%81.jpg" alt="支付宝"></div>
</a>

                
                
<a class="button is-success donate">
    <span class="icon is-small">
        <i class="fab fa-weixin"></i>
    </span>
    <span>微信</span>
    <div class="qrcode"><img src="/images/%E5%BE%AE%E4%BF%A1%E8%B5%9E%E8%B5%8F%E7%A0%81.png" alt="微信"></div>
</a>

                
        </div>
    </div>
</div>



<div class="card card-transparent">
    <div class="level post-navigation is-flex-wrap is-mobile">
        
        <div class="level-start">
            <a class="level level-item has-link-grey  article-nav-prev" href="/2019-2-12-scipy-misc%E4%B8%8D%E5%AD%98%E5%9C%A8toimage%E7%9A%84%E8%A7%A3%E5%86%B3%E6%96%B9%E6%A1%88/">
                <i class="level-item fas fa-chevron-left"></i>
                <span class="level-item">scipy.misc不存在toimage的解决方案</span>
            </a>
        </div>
        
        
        <div class="level-end">
            <a class="level level-item has-link-grey  article-nav-next" href="/2018-12-06-JSP%E5%A4%A7%E4%BD%9C%E4%B8%9A-%E5%AE%9E%E9%AA%8C%E5%AE%A4%E5%AD%A6%E7%94%9F%E7%AE%A1%E7%90%86%E7%B3%BB%E7%BB%9F/">
                <span class="level-item">JSP大作业-学生管理系统</span>
                <i class="level-item fas fa-chevron-right"></i>
            </a>
        </div>
        
    </div>
</div>



<div class="card">
    <div class="card-content">
        <h3 class="title is-5 has-text-weight-normal">评论</h3>
        
<div id="valine-thread" class="content"></div>
<script src="//cdn1.lncld.net/static/js/3.0.4/av-min.js"></script>
<script src="https://cdn.jsdelivr.net/npm/valine@1.3.10/dist/Valine.min.js"></script>
<script>
    new Valine({
        el: '#valine-thread' ,
        notify: true,
        verify: true,
        app_id: 'DNC4dhA3KwUWSaeLWxwFjSmD-gzGzoHsz',
        app_key: 'ileLtaXmaLu8lsvqSqIAg195',
        placeholder: 'xxxxxxxx'
    });
</script>

    </div>
</div>

</div>
                




<div class="column is-4-tablet is-4-desktop is-3-widescreen  has-order-1 column-left is-sticky">
    
        
<div class="card widget">
    <div class="card-content">
        <nav class="level">
            <div class="level-item has-text-centered" style="flex-shrink: 1">
                <div>
                    
                    <figure class="image is-128x128 has-mb-6">
                        <img class="" src="/images/%E6%B1%9D%E7%AD%89%E7%9C%8B%E5%A5%BD%E6%88%91%E6%98%AF%E4%BD%A0%E4%B9%94%E5%93%A5%E7%81%B5%E5%8A%A8%E5%A4%B4%E5%83%8F.jpg" alt="王政乔">
                    </figure>
                    
                    <p class="is-size-4 is-block">
                        王政乔
                    </p>
                    
                    
                    <p class="is-size-6 is-block">
                        毕业啦！！！准备工作！
                    </p>
                    
                    
                    <p class="is-size-6 is-flex is-flex-center has-text-grey">
                        <i class="fas fa-map-marker-alt has-mr-7"></i>
                        <span>中华人民共和国 河南省 郑州市</span>
                    </p>
                    
                </div>
            </div>
        </nav>
        <nav class="level is-mobile">
            <div class="level-item has-text-centered is-marginless">
                <div>
                    <p class="heading">
                        文章
                    </p>
                    <a href="/archives">
                        <p class="title has-text-weight-normal">
                            67
                        </p>
                    </a>
                </div>
            </div>
            <div class="level-item has-text-centered is-marginless">
                <div>
                    <p class="heading">
                        分类
                    </p>
                    <a href="/categories">
                        <p class="title has-text-weight-normal">
                            17
                        </p>
                    </a>
                </div>
            </div>
            <div class="level-item has-text-centered is-marginless">
                <div>
                    <p class="heading">
                        标签
                    </p>
                    <a href="/tags">
                        <p class="title has-text-weight-normal">
                            48
                        </p>
                    </a>
                </div>
            </div>
        </nav>
        
        <div class="level">
            <a class="level-item button is-link is-rounded" href="https://gitee.com/JogerQiao" target="_blank" rel="noopener">
                关注我</a>
        </div>
        
        
        
        <div class="level is-mobile">
            
            <a class="level-item button is-white is-marginless" target="_blank" rel="noopener"
                title="Gitee" href="https://gitee.com/JogerQiao">
                
                <i class="iconfont icon-gitee-fill-round"></i>
                
            </a>
            
            <a class="level-item button is-white is-marginless" target="_blank" rel="noopener"
                title="知乎" href="https://www.zhihu.com/people/joger-81">
                
                <i class="iconfont icon-zhihu"></i>
                
            </a>
            
            <a class="level-item button is-white is-marginless" target="_blank" rel="noopener"
                title="我的邮箱" href="mailto:me@zhengqiao.wang">
                
                <i class="iconfont icon-mail"></i>
                
            </a>
            
            <a class="level-item button is-white is-marginless" target="_blank" rel="noopener"
                title="Bilibili" href="https://space.bilibili.com/83542572">
                
                <i class="iconfont icon-bilibili-line"></i>
                
            </a>
            
        </div>
        
    </div>
</div>
    
        

    <div class="card widget" id="toc">
        <div class="card-content">
            <div class="menu">
                <h3 class="menu-label">
                    目录
                </h3>
                <ul class="menu-list"><li>
        <a class="is-flex" href="#编译原理实验三：算符优先算法实现-半成品">
        <span class="has-mr-6">1</span>
        <span>编译原理实验三：算符优先算法实现(半成品)</span>
        </a></li></ul>
            </div>
        </div>
    </div>

    
        <div class="card widget">
    <div class="card-content">
        <div class="menu">
        <h3 class="menu-label">
            链接
        </h3>
        <ul class="menu-list">
        
            <li>
                <a class="level is-mobile" href="https://hexo.io" target="_blank" rel="noopener">
                    <span class="level-left">
                        <span class="level-item">Hexo</span>
                    </span>
                    <span class="level-right">
                        <span class="level-item tag">hexo.io</span>
                    </span>
                </a>
            </li>
        
            <li>
                <a class="level is-mobile" href="https://github.com/ppoffice" target="_blank" rel="noopener">
                    <span class="level-left">
                        <span class="level-item">PPOffice</span>
                    </span>
                    <span class="level-right">
                        <span class="level-item tag">github.com</span>
                    </span>
                </a>
            </li>
        
            <li>
                <a class="level is-mobile" href="http://mtics.top" target="_blank" rel="noopener">
                    <span class="level-left">
                        <span class="level-item">李志伟-吾人为学</span>
                    </span>
                    <span class="level-right">
                        <span class="level-item tag">mtics.top</span>
                    </span>
                </a>
            </li>
        
            <li>
                <a class="level is-mobile" href="https://expoli.tech/" target="_blank" rel="noopener">
                    <span class="level-left">
                        <span class="level-item">糖醋鱼</span>
                    </span>
                    <span class="level-right">
                        <span class="level-item tag">expoli.tech</span>
                    </span>
                </a>
            </li>
        
            <li>
                <a class="level is-mobile" href="https://zzuyy519blog.top/" target="_blank" rel="noopener">
                    <span class="level-left">
                        <span class="level-item">羊老头</span>
                    </span>
                    <span class="level-right">
                        <span class="level-item tag">zzuyy519blog.top</span>
                    </span>
                </a>
            </li>
        
            <li>
                <a class="level is-mobile" href="https://shuangzu.top/" target="_blank" rel="noopener">
                    <span class="level-left">
                        <span class="level-item">郑州大学双足实验室</span>
                    </span>
                    <span class="level-right">
                        <span class="level-item tag">shuangzu.top</span>
                    </span>
                </a>
            </li>
        
            <li>
                <a class="level is-mobile" href="https://www.leeyiding.com/" target="_blank" rel="noopener">
                    <span class="level-left">
                        <span class="level-item">LeeYD · Blog</span>
                    </span>
                    <span class="level-right">
                        <span class="level-item tag">www.leeyiding.com</span>
                    </span>
                </a>
            </li>
        
            <li>
                <a class="level is-mobile" href="https://shiyousan.com/" target="_blank" rel="noopener">
                    <span class="level-left">
                        <span class="level-item">十有三</span>
                    </span>
                    <span class="level-right">
                        <span class="level-item tag">shiyousan.com</span>
                    </span>
                </a>
            </li>
        
        </ul>
        </div>
    </div>
</div>

    
    
        <div class="column-right-shadow is-hidden-widescreen ">
        
            
<div class="card widget">
    <div class="card-content">
        <div class="menu">
            <h3 class="menu-label">
                分类
            </h3>
            <ul class="menu-list">
            <li>
        <a class="level is-marginless" href="/categories/%E5%85%AC%E5%91%8A/">
            <span class="level-start">
                <span class="level-item">公告</span>
            </span>
            <span class="level-end">
                <span class="level-item tag">1</span>
            </span>
        </a></li><li>
        <a class="level is-marginless" href="/categories/%E6%8A%80%E6%9C%AF%E5%88%86%E4%BA%AB/">
            <span class="level-start">
                <span class="level-item">技术分享</span>
            </span>
            <span class="level-end">
                <span class="level-item tag">58</span>
            </span>
        </a><ul><li>
        <a class="level is-marginless" href="/categories/%E6%8A%80%E6%9C%AF%E5%88%86%E4%BA%AB/Android/">
            <span class="level-start">
                <span class="level-item">Android</span>
            </span>
            <span class="level-end">
                <span class="level-item tag">4</span>
            </span>
        </a></li><li>
        <a class="level is-marginless" href="/categories/%E6%8A%80%E6%9C%AF%E5%88%86%E4%BA%AB/C/">
            <span class="level-start">
                <span class="level-item">C++</span>
            </span>
            <span class="level-end">
                <span class="level-item tag">14</span>
            </span>
        </a></li><li>
        <a class="level is-marginless" href="/categories/%E6%8A%80%E6%9C%AF%E5%88%86%E4%BA%AB/Docker/">
            <span class="level-start">
                <span class="level-item">Docker</span>
            </span>
            <span class="level-end">
                <span class="level-item tag">1</span>
            </span>
        </a></li><li>
        <a class="level is-marginless" href="/categories/%E6%8A%80%E6%9C%AF%E5%88%86%E4%BA%AB/Java/">
            <span class="level-start">
                <span class="level-item">Java</span>
            </span>
            <span class="level-end">
                <span class="level-item tag">6</span>
            </span>
        </a></li><li>
        <a class="level is-marginless" href="/categories/%E6%8A%80%E6%9C%AF%E5%88%86%E4%BA%AB/Linux/">
            <span class="level-start">
                <span class="level-item">Linux</span>
            </span>
            <span class="level-end">
                <span class="level-item tag">3</span>
            </span>
        </a></li><li>
        <a class="level is-marginless" href="/categories/%E6%8A%80%E6%9C%AF%E5%88%86%E4%BA%AB/NAO/">
            <span class="level-start">
                <span class="level-item">NAO</span>
            </span>
            <span class="level-end">
                <span class="level-item tag">7</span>
            </span>
        </a></li><li>
        <a class="level is-marginless" href="/categories/%E6%8A%80%E6%9C%AF%E5%88%86%E4%BA%AB/Python/">
            <span class="level-start">
                <span class="level-item">Python</span>
            </span>
            <span class="level-end">
                <span class="level-item tag">5</span>
            </span>
        </a></li><li>
        <a class="level is-marginless" href="/categories/%E6%8A%80%E6%9C%AF%E5%88%86%E4%BA%AB/%E5%89%8D%E7%AB%AF/">
            <span class="level-start">
                <span class="level-item">前端</span>
            </span>
            <span class="level-end">
                <span class="level-item tag">5</span>
            </span>
        </a></li><li>
        <a class="level is-marginless" href="/categories/%E6%8A%80%E6%9C%AF%E5%88%86%E4%BA%AB/%E5%8C%BB%E5%AD%A6%E5%9B%BE%E5%83%8F/">
            <span class="level-start">
                <span class="level-item">医学图像</span>
            </span>
            <span class="level-end">
                <span class="level-item tag">2</span>
            </span>
        </a></li><li>
        <a class="level is-marginless" href="/categories/%E6%8A%80%E6%9C%AF%E5%88%86%E4%BA%AB/%E6%9C%BA%E5%99%A8%E5%AD%A6%E4%B9%A0/">
            <span class="level-start">
                <span class="level-item">机器学习</span>
            </span>
            <span class="level-end">
                <span class="level-item tag">5</span>
            </span>
        </a></li><li>
        <a class="level is-marginless" href="/categories/%E6%8A%80%E6%9C%AF%E5%88%86%E4%BA%AB/%E6%A0%91%E8%8E%93%E6%B4%BE/">
            <span class="level-start">
                <span class="level-item">树莓派</span>
            </span>
            <span class="level-end">
                <span class="level-item tag">5</span>
            </span>
        </a></li></ul></li><li>
        <a class="level is-marginless" href="/categories/%E8%AF%BE%E7%A8%8B%E8%AE%BE%E8%AE%A1/">
            <span class="level-start">
                <span class="level-item">课程设计</span>
            </span>
            <span class="level-end">
                <span class="level-item tag">4</span>
            </span>
        </a><ul><li>
        <a class="level is-marginless" href="/categories/%E8%AF%BE%E7%A8%8B%E8%AE%BE%E8%AE%A1/%E5%B5%8C%E5%85%A5%E5%BC%8F/">
            <span class="level-start">
                <span class="level-item">嵌入式</span>
            </span>
            <span class="level-end">
                <span class="level-item tag">1</span>
            </span>
        </a></li><li>
        <a class="level is-marginless" href="/categories/%E8%AF%BE%E7%A8%8B%E8%AE%BE%E8%AE%A1/%E7%BC%96%E8%AF%91%E5%8E%9F%E7%90%86/">
            <span class="level-start">
                <span class="level-item">编译原理</span>
            </span>
            <span class="level-end">
                <span class="level-item tag">3</span>
            </span>
        </a></li></ul></li><li>
        <a class="level is-marginless" href="/categories/%E9%9A%8F%E7%AC%94/">
            <span class="level-start">
                <span class="level-item">随笔</span>
            </span>
            <span class="level-end">
                <span class="level-item tag">4</span>
            </span>
        </a></li>
            </ul>
        </div>
    </div>
</div>
        
            <div class="card widget">
    <div class="card-content">
        <div class="menu">
        <h3 class="menu-label">
            归档
        </h3>
        <ul class="menu-list">
        
        <li>
            <a class="level is-marginless" href="/archives/2020/10/">
                <span class="level-start">
                    <span class="level-item">十月 2020</span>
                </span>
                <span class="level-end">
                    <span class="level-item tag">1</span>
                </span>
            </a>
        </li>
        
        <li>
            <a class="level is-marginless" href="/archives/2020/05/">
                <span class="level-start">
                    <span class="level-item">五月 2020</span>
                </span>
                <span class="level-end">
                    <span class="level-item tag">1</span>
                </span>
            </a>
        </li>
        
        <li>
            <a class="level is-marginless" href="/archives/2020/04/">
                <span class="level-start">
                    <span class="level-item">四月 2020</span>
                </span>
                <span class="level-end">
                    <span class="level-item tag">5</span>
                </span>
            </a>
        </li>
        
        <li>
            <a class="level is-marginless" href="/archives/2020/03/">
                <span class="level-start">
                    <span class="level-item">三月 2020</span>
                </span>
                <span class="level-end">
                    <span class="level-item tag">18</span>
                </span>
            </a>
        </li>
        
        <li>
            <a class="level is-marginless" href="/archives/2019/11/">
                <span class="level-start">
                    <span class="level-item">十一月 2019</span>
                </span>
                <span class="level-end">
                    <span class="level-item tag">5</span>
                </span>
            </a>
        </li>
        
        <li>
            <a class="level is-marginless" href="/archives/2019/10/">
                <span class="level-start">
                    <span class="level-item">十月 2019</span>
                </span>
                <span class="level-end">
                    <span class="level-item tag">1</span>
                </span>
            </a>
        </li>
        
        <li>
            <a class="level is-marginless" href="/archives/2019/09/">
                <span class="level-start">
                    <span class="level-item">九月 2019</span>
                </span>
                <span class="level-end">
                    <span class="level-item tag">1</span>
                </span>
            </a>
        </li>
        
        <li>
            <a class="level is-marginless" href="/archives/2019/08/">
                <span class="level-start">
                    <span class="level-item">八月 2019</span>
                </span>
                <span class="level-end">
                    <span class="level-item tag">4</span>
                </span>
            </a>
        </li>
        
        <li>
            <a class="level is-marginless" href="/archives/2019/06/">
                <span class="level-start">
                    <span class="level-item">六月 2019</span>
                </span>
                <span class="level-end">
                    <span class="level-item tag">1</span>
                </span>
            </a>
        </li>
        
        <li>
            <a class="level is-marginless" href="/archives/2019/04/">
                <span class="level-start">
                    <span class="level-item">四月 2019</span>
                </span>
                <span class="level-end">
                    <span class="level-item tag">1</span>
                </span>
            </a>
        </li>
        
        <li>
            <a class="level is-marginless" href="/archives/2019/03/">
                <span class="level-start">
                    <span class="level-item">三月 2019</span>
                </span>
                <span class="level-end">
                    <span class="level-item tag">4</span>
                </span>
            </a>
        </li>
        
        <li>
            <a class="level is-marginless" href="/archives/2019/02/">
                <span class="level-start">
                    <span class="level-item">二月 2019</span>
                </span>
                <span class="level-end">
                    <span class="level-item tag">4</span>
                </span>
            </a>
        </li>
        
        <li>
            <a class="level is-marginless" href="/archives/2018/12/">
                <span class="level-start">
                    <span class="level-item">十二月 2018</span>
                </span>
                <span class="level-end">
                    <span class="level-item tag">2</span>
                </span>
            </a>
        </li>
        
        <li>
            <a class="level is-marginless" href="/archives/2018/11/">
                <span class="level-start">
                    <span class="level-item">十一月 2018</span>
                </span>
                <span class="level-end">
                    <span class="level-item tag">5</span>
                </span>
            </a>
        </li>
        
        <li>
            <a class="level is-marginless" href="/archives/2018/10/">
                <span class="level-start">
                    <span class="level-item">十月 2018</span>
                </span>
                <span class="level-end">
                    <span class="level-item tag">9</span>
                </span>
            </a>
        </li>
        
        <li>
            <a class="level is-marginless" href="/archives/2018/05/">
                <span class="level-start">
                    <span class="level-item">五月 2018</span>
                </span>
                <span class="level-end">
                    <span class="level-item tag">1</span>
                </span>
            </a>
        </li>
        
        <li>
            <a class="level is-marginless" href="/archives/2018/04/">
                <span class="level-start">
                    <span class="level-item">四月 2018</span>
                </span>
                <span class="level-end">
                    <span class="level-item tag">1</span>
                </span>
            </a>
        </li>
        
        <li>
            <a class="level is-marginless" href="/archives/2018/03/">
                <span class="level-start">
                    <span class="level-item">三月 2018</span>
                </span>
                <span class="level-end">
                    <span class="level-item tag">1</span>
                </span>
            </a>
        </li>
        
        <li>
            <a class="level is-marginless" href="/archives/2018/02/">
                <span class="level-start">
                    <span class="level-item">二月 2018</span>
                </span>
                <span class="level-end">
                    <span class="level-item tag">2</span>
                </span>
            </a>
        </li>
        
        </ul>
        </div>
    </div>
</div>
        
            <div class="card widget">
    <div class="card-content">
        <div class="menu">
            <h3 class="menu-label">
                标签
            </h3>
            <div class="field is-grouped is-grouped-multiline">
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/AX-12/">
                        <span class="tag">AX-12</span>
                        <span class="tag is-grey">1</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/Android/">
                        <span class="tag">Android</span>
                        <span class="tag is-grey">4</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/Bluetooth/">
                        <span class="tag">Bluetooth</span>
                        <span class="tag is-grey">1</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/C/">
                        <span class="tag">C++</span>
                        <span class="tag is-grey">15</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/CSI%E6%91%84%E5%83%8F%E5%A4%B4/">
                        <span class="tag">CSI摄像头</span>
                        <span class="tag is-grey">1</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/CSS/">
                        <span class="tag">CSS</span>
                        <span class="tag is-grey">2</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/CV/">
                        <span class="tag">CV</span>
                        <span class="tag is-grey">4</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/Choregraphe/">
                        <span class="tag">Choregraphe</span>
                        <span class="tag is-grey">1</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/DCMTK/">
                        <span class="tag">DCMTK</span>
                        <span class="tag is-grey">1</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/Docker/">
                        <span class="tag">Docker</span>
                        <span class="tag is-grey">1</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/HTML/">
                        <span class="tag">HTML</span>
                        <span class="tag is-grey">4</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/Handle/">
                        <span class="tag">Handle</span>
                        <span class="tag is-grey">1</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/Hexo/">
                        <span class="tag">Hexo</span>
                        <span class="tag is-grey">1</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/IDEA/">
                        <span class="tag">IDEA</span>
                        <span class="tag is-grey">1</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/Java/">
                        <span class="tag">Java</span>
                        <span class="tag is-grey">6</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/JavaScript/">
                        <span class="tag">JavaScript</span>
                        <span class="tag is-grey">1</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/Linux/">
                        <span class="tag">Linux</span>
                        <span class="tag is-grey">5</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/Mysql/">
                        <span class="tag">Mysql</span>
                        <span class="tag is-grey">1</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/NAO/">
                        <span class="tag">NAO</span>
                        <span class="tag is-grey">6</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/NAO%E6%9C%BA%E5%99%A8%E4%BA%BA/">
                        <span class="tag">NAO机器人</span>
                        <span class="tag is-grey">1</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/Nao/">
                        <span class="tag">Nao</span>
                        <span class="tag is-grey">1</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/OpenCV/">
                        <span class="tag">OpenCV</span>
                        <span class="tag is-grey">2</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/Python/">
                        <span class="tag">Python</span>
                        <span class="tag is-grey">8</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/Python-Pip/">
                        <span class="tag">Python - Pip</span>
                        <span class="tag is-grey">1</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/Qt/">
                        <span class="tag">Qt</span>
                        <span class="tag is-grey">2</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/Raspberry-Pi-3b/">
                        <span class="tag">Raspberry Pi 3b</span>
                        <span class="tag is-grey">5</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/SDK/">
                        <span class="tag">SDK</span>
                        <span class="tag is-grey">1</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/SVM/">
                        <span class="tag">SVM</span>
                        <span class="tag is-grey">1</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/Shell/">
                        <span class="tag">Shell</span>
                        <span class="tag is-grey">1</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/Tensorflow/">
                        <span class="tag">Tensorflow</span>
                        <span class="tag is-grey">3</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/Tomcat/">
                        <span class="tag">Tomcat</span>
                        <span class="tag is-grey">2</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/Unix/">
                        <span class="tag">Unix</span>
                        <span class="tag is-grey">1</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/VSCode/">
                        <span class="tag">VSCode</span>
                        <span class="tag is-grey">1</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/WordPress/">
                        <span class="tag">WordPress</span>
                        <span class="tag is-grey">1</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/python/">
                        <span class="tag">python</span>
                        <span class="tag is-grey">8</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/ssh/">
                        <span class="tag">ssh</span>
                        <span class="tag is-grey">1</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/%E4%BB%A3%E7%A0%81%E5%AD%98%E6%A1%A3/">
                        <span class="tag">代码存档</span>
                        <span class="tag is-grey">2</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/%E5%8C%BB%E5%AD%A6%E5%9B%BE%E5%83%8F/">
                        <span class="tag">医学图像</span>
                        <span class="tag is-grey">2</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/%E5%A4%A7%E6%95%B0%E6%8D%AE/">
                        <span class="tag">大数据</span>
                        <span class="tag is-grey">2</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/%E5%B5%8C%E5%85%A5%E5%BC%8F-STM32/">
                        <span class="tag">嵌入式 - STM32</span>
                        <span class="tag is-grey">1</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/%E6%8B%A6%E6%88%AA%E5%99%A8/">
                        <span class="tag">拦截器</span>
                        <span class="tag is-grey">1</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/%E6%95%99%E7%A8%8B/">
                        <span class="tag">教程</span>
                        <span class="tag is-grey">2</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/%E7%89%B9%E5%BE%81%E5%B7%A5%E7%A8%8B/">
                        <span class="tag">特征工程</span>
                        <span class="tag is-grey">1</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/%E7%AC%AC%E4%B8%89%E6%96%B9%E5%BA%93/">
                        <span class="tag">第三方库</span>
                        <span class="tag is-grey">1</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/%E7%BA%A2%E7%90%83%E6%A3%80%E6%B5%8B/">
                        <span class="tag">红球检测</span>
                        <span class="tag is-grey">1</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/%E7%BC%96%E8%AF%91%E5%8E%9F%E7%90%86/">
                        <span class="tag">编译原理</span>
                        <span class="tag is-grey">2</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/%E8%A7%A3%E5%86%B3%E6%96%B9%E6%A1%88/">
                        <span class="tag">解决方案</span>
                        <span class="tag is-grey">6</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/%E9%9A%8F%E7%AC%94/">
                        <span class="tag">随笔</span>
                        <span class="tag is-grey">4</span>
                    </a>
                </div>
                
            </div>
        </div>
    </div>
</div>
        
        </div>
    
</div>

                




<div class="column is-4-tablet is-4-desktop is-3-widescreen is-hidden-touch is-hidden-desktop-only has-order-3 column-right ">
    
        
<div class="card widget">
    <div class="card-content">
        <div class="menu">
            <h3 class="menu-label">
                分类
            </h3>
            <ul class="menu-list">
            <li>
        <a class="level is-marginless" href="/categories/%E5%85%AC%E5%91%8A/">
            <span class="level-start">
                <span class="level-item">公告</span>
            </span>
            <span class="level-end">
                <span class="level-item tag">1</span>
            </span>
        </a></li><li>
        <a class="level is-marginless" href="/categories/%E6%8A%80%E6%9C%AF%E5%88%86%E4%BA%AB/">
            <span class="level-start">
                <span class="level-item">技术分享</span>
            </span>
            <span class="level-end">
                <span class="level-item tag">58</span>
            </span>
        </a><ul><li>
        <a class="level is-marginless" href="/categories/%E6%8A%80%E6%9C%AF%E5%88%86%E4%BA%AB/Android/">
            <span class="level-start">
                <span class="level-item">Android</span>
            </span>
            <span class="level-end">
                <span class="level-item tag">4</span>
            </span>
        </a></li><li>
        <a class="level is-marginless" href="/categories/%E6%8A%80%E6%9C%AF%E5%88%86%E4%BA%AB/C/">
            <span class="level-start">
                <span class="level-item">C++</span>
            </span>
            <span class="level-end">
                <span class="level-item tag">14</span>
            </span>
        </a></li><li>
        <a class="level is-marginless" href="/categories/%E6%8A%80%E6%9C%AF%E5%88%86%E4%BA%AB/Docker/">
            <span class="level-start">
                <span class="level-item">Docker</span>
            </span>
            <span class="level-end">
                <span class="level-item tag">1</span>
            </span>
        </a></li><li>
        <a class="level is-marginless" href="/categories/%E6%8A%80%E6%9C%AF%E5%88%86%E4%BA%AB/Java/">
            <span class="level-start">
                <span class="level-item">Java</span>
            </span>
            <span class="level-end">
                <span class="level-item tag">6</span>
            </span>
        </a></li><li>
        <a class="level is-marginless" href="/categories/%E6%8A%80%E6%9C%AF%E5%88%86%E4%BA%AB/Linux/">
            <span class="level-start">
                <span class="level-item">Linux</span>
            </span>
            <span class="level-end">
                <span class="level-item tag">3</span>
            </span>
        </a></li><li>
        <a class="level is-marginless" href="/categories/%E6%8A%80%E6%9C%AF%E5%88%86%E4%BA%AB/NAO/">
            <span class="level-start">
                <span class="level-item">NAO</span>
            </span>
            <span class="level-end">
                <span class="level-item tag">7</span>
            </span>
        </a></li><li>
        <a class="level is-marginless" href="/categories/%E6%8A%80%E6%9C%AF%E5%88%86%E4%BA%AB/Python/">
            <span class="level-start">
                <span class="level-item">Python</span>
            </span>
            <span class="level-end">
                <span class="level-item tag">5</span>
            </span>
        </a></li><li>
        <a class="level is-marginless" href="/categories/%E6%8A%80%E6%9C%AF%E5%88%86%E4%BA%AB/%E5%89%8D%E7%AB%AF/">
            <span class="level-start">
                <span class="level-item">前端</span>
            </span>
            <span class="level-end">
                <span class="level-item tag">5</span>
            </span>
        </a></li><li>
        <a class="level is-marginless" href="/categories/%E6%8A%80%E6%9C%AF%E5%88%86%E4%BA%AB/%E5%8C%BB%E5%AD%A6%E5%9B%BE%E5%83%8F/">
            <span class="level-start">
                <span class="level-item">医学图像</span>
            </span>
            <span class="level-end">
                <span class="level-item tag">2</span>
            </span>
        </a></li><li>
        <a class="level is-marginless" href="/categories/%E6%8A%80%E6%9C%AF%E5%88%86%E4%BA%AB/%E6%9C%BA%E5%99%A8%E5%AD%A6%E4%B9%A0/">
            <span class="level-start">
                <span class="level-item">机器学习</span>
            </span>
            <span class="level-end">
                <span class="level-item tag">5</span>
            </span>
        </a></li><li>
        <a class="level is-marginless" href="/categories/%E6%8A%80%E6%9C%AF%E5%88%86%E4%BA%AB/%E6%A0%91%E8%8E%93%E6%B4%BE/">
            <span class="level-start">
                <span class="level-item">树莓派</span>
            </span>
            <span class="level-end">
                <span class="level-item tag">5</span>
            </span>
        </a></li></ul></li><li>
        <a class="level is-marginless" href="/categories/%E8%AF%BE%E7%A8%8B%E8%AE%BE%E8%AE%A1/">
            <span class="level-start">
                <span class="level-item">课程设计</span>
            </span>
            <span class="level-end">
                <span class="level-item tag">4</span>
            </span>
        </a><ul><li>
        <a class="level is-marginless" href="/categories/%E8%AF%BE%E7%A8%8B%E8%AE%BE%E8%AE%A1/%E5%B5%8C%E5%85%A5%E5%BC%8F/">
            <span class="level-start">
                <span class="level-item">嵌入式</span>
            </span>
            <span class="level-end">
                <span class="level-item tag">1</span>
            </span>
        </a></li><li>
        <a class="level is-marginless" href="/categories/%E8%AF%BE%E7%A8%8B%E8%AE%BE%E8%AE%A1/%E7%BC%96%E8%AF%91%E5%8E%9F%E7%90%86/">
            <span class="level-start">
                <span class="level-item">编译原理</span>
            </span>
            <span class="level-end">
                <span class="level-item tag">3</span>
            </span>
        </a></li></ul></li><li>
        <a class="level is-marginless" href="/categories/%E9%9A%8F%E7%AC%94/">
            <span class="level-start">
                <span class="level-item">随笔</span>
            </span>
            <span class="level-end">
                <span class="level-item tag">4</span>
            </span>
        </a></li>
            </ul>
        </div>
    </div>
</div>
    
        <div class="card widget">
    <div class="card-content">
        <div class="menu">
        <h3 class="menu-label">
            归档
        </h3>
        <ul class="menu-list">
        
        <li>
            <a class="level is-marginless" href="/archives/2020/10/">
                <span class="level-start">
                    <span class="level-item">十月 2020</span>
                </span>
                <span class="level-end">
                    <span class="level-item tag">1</span>
                </span>
            </a>
        </li>
        
        <li>
            <a class="level is-marginless" href="/archives/2020/05/">
                <span class="level-start">
                    <span class="level-item">五月 2020</span>
                </span>
                <span class="level-end">
                    <span class="level-item tag">1</span>
                </span>
            </a>
        </li>
        
        <li>
            <a class="level is-marginless" href="/archives/2020/04/">
                <span class="level-start">
                    <span class="level-item">四月 2020</span>
                </span>
                <span class="level-end">
                    <span class="level-item tag">5</span>
                </span>
            </a>
        </li>
        
        <li>
            <a class="level is-marginless" href="/archives/2020/03/">
                <span class="level-start">
                    <span class="level-item">三月 2020</span>
                </span>
                <span class="level-end">
                    <span class="level-item tag">18</span>
                </span>
            </a>
        </li>
        
        <li>
            <a class="level is-marginless" href="/archives/2019/11/">
                <span class="level-start">
                    <span class="level-item">十一月 2019</span>
                </span>
                <span class="level-end">
                    <span class="level-item tag">5</span>
                </span>
            </a>
        </li>
        
        <li>
            <a class="level is-marginless" href="/archives/2019/10/">
                <span class="level-start">
                    <span class="level-item">十月 2019</span>
                </span>
                <span class="level-end">
                    <span class="level-item tag">1</span>
                </span>
            </a>
        </li>
        
        <li>
            <a class="level is-marginless" href="/archives/2019/09/">
                <span class="level-start">
                    <span class="level-item">九月 2019</span>
                </span>
                <span class="level-end">
                    <span class="level-item tag">1</span>
                </span>
            </a>
        </li>
        
        <li>
            <a class="level is-marginless" href="/archives/2019/08/">
                <span class="level-start">
                    <span class="level-item">八月 2019</span>
                </span>
                <span class="level-end">
                    <span class="level-item tag">4</span>
                </span>
            </a>
        </li>
        
        <li>
            <a class="level is-marginless" href="/archives/2019/06/">
                <span class="level-start">
                    <span class="level-item">六月 2019</span>
                </span>
                <span class="level-end">
                    <span class="level-item tag">1</span>
                </span>
            </a>
        </li>
        
        <li>
            <a class="level is-marginless" href="/archives/2019/04/">
                <span class="level-start">
                    <span class="level-item">四月 2019</span>
                </span>
                <span class="level-end">
                    <span class="level-item tag">1</span>
                </span>
            </a>
        </li>
        
        <li>
            <a class="level is-marginless" href="/archives/2019/03/">
                <span class="level-start">
                    <span class="level-item">三月 2019</span>
                </span>
                <span class="level-end">
                    <span class="level-item tag">4</span>
                </span>
            </a>
        </li>
        
        <li>
            <a class="level is-marginless" href="/archives/2019/02/">
                <span class="level-start">
                    <span class="level-item">二月 2019</span>
                </span>
                <span class="level-end">
                    <span class="level-item tag">4</span>
                </span>
            </a>
        </li>
        
        <li>
            <a class="level is-marginless" href="/archives/2018/12/">
                <span class="level-start">
                    <span class="level-item">十二月 2018</span>
                </span>
                <span class="level-end">
                    <span class="level-item tag">2</span>
                </span>
            </a>
        </li>
        
        <li>
            <a class="level is-marginless" href="/archives/2018/11/">
                <span class="level-start">
                    <span class="level-item">十一月 2018</span>
                </span>
                <span class="level-end">
                    <span class="level-item tag">5</span>
                </span>
            </a>
        </li>
        
        <li>
            <a class="level is-marginless" href="/archives/2018/10/">
                <span class="level-start">
                    <span class="level-item">十月 2018</span>
                </span>
                <span class="level-end">
                    <span class="level-item tag">9</span>
                </span>
            </a>
        </li>
        
        <li>
            <a class="level is-marginless" href="/archives/2018/05/">
                <span class="level-start">
                    <span class="level-item">五月 2018</span>
                </span>
                <span class="level-end">
                    <span class="level-item tag">1</span>
                </span>
            </a>
        </li>
        
        <li>
            <a class="level is-marginless" href="/archives/2018/04/">
                <span class="level-start">
                    <span class="level-item">四月 2018</span>
                </span>
                <span class="level-end">
                    <span class="level-item tag">1</span>
                </span>
            </a>
        </li>
        
        <li>
            <a class="level is-marginless" href="/archives/2018/03/">
                <span class="level-start">
                    <span class="level-item">三月 2018</span>
                </span>
                <span class="level-end">
                    <span class="level-item tag">1</span>
                </span>
            </a>
        </li>
        
        <li>
            <a class="level is-marginless" href="/archives/2018/02/">
                <span class="level-start">
                    <span class="level-item">二月 2018</span>
                </span>
                <span class="level-end">
                    <span class="level-item tag">2</span>
                </span>
            </a>
        </li>
        
        </ul>
        </div>
    </div>
</div>
    
        <div class="card widget">
    <div class="card-content">
        <div class="menu">
            <h3 class="menu-label">
                标签
            </h3>
            <div class="field is-grouped is-grouped-multiline">
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/AX-12/">
                        <span class="tag">AX-12</span>
                        <span class="tag is-grey">1</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/Android/">
                        <span class="tag">Android</span>
                        <span class="tag is-grey">4</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/Bluetooth/">
                        <span class="tag">Bluetooth</span>
                        <span class="tag is-grey">1</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/C/">
                        <span class="tag">C++</span>
                        <span class="tag is-grey">15</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/CSI%E6%91%84%E5%83%8F%E5%A4%B4/">
                        <span class="tag">CSI摄像头</span>
                        <span class="tag is-grey">1</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/CSS/">
                        <span class="tag">CSS</span>
                        <span class="tag is-grey">2</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/CV/">
                        <span class="tag">CV</span>
                        <span class="tag is-grey">4</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/Choregraphe/">
                        <span class="tag">Choregraphe</span>
                        <span class="tag is-grey">1</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/DCMTK/">
                        <span class="tag">DCMTK</span>
                        <span class="tag is-grey">1</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/Docker/">
                        <span class="tag">Docker</span>
                        <span class="tag is-grey">1</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/HTML/">
                        <span class="tag">HTML</span>
                        <span class="tag is-grey">4</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/Handle/">
                        <span class="tag">Handle</span>
                        <span class="tag is-grey">1</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/Hexo/">
                        <span class="tag">Hexo</span>
                        <span class="tag is-grey">1</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/IDEA/">
                        <span class="tag">IDEA</span>
                        <span class="tag is-grey">1</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/Java/">
                        <span class="tag">Java</span>
                        <span class="tag is-grey">6</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/JavaScript/">
                        <span class="tag">JavaScript</span>
                        <span class="tag is-grey">1</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/Linux/">
                        <span class="tag">Linux</span>
                        <span class="tag is-grey">5</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/Mysql/">
                        <span class="tag">Mysql</span>
                        <span class="tag is-grey">1</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/NAO/">
                        <span class="tag">NAO</span>
                        <span class="tag is-grey">6</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/NAO%E6%9C%BA%E5%99%A8%E4%BA%BA/">
                        <span class="tag">NAO机器人</span>
                        <span class="tag is-grey">1</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/Nao/">
                        <span class="tag">Nao</span>
                        <span class="tag is-grey">1</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/OpenCV/">
                        <span class="tag">OpenCV</span>
                        <span class="tag is-grey">2</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/Python/">
                        <span class="tag">Python</span>
                        <span class="tag is-grey">8</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/Python-Pip/">
                        <span class="tag">Python - Pip</span>
                        <span class="tag is-grey">1</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/Qt/">
                        <span class="tag">Qt</span>
                        <span class="tag is-grey">2</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/Raspberry-Pi-3b/">
                        <span class="tag">Raspberry Pi 3b</span>
                        <span class="tag is-grey">5</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/SDK/">
                        <span class="tag">SDK</span>
                        <span class="tag is-grey">1</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/SVM/">
                        <span class="tag">SVM</span>
                        <span class="tag is-grey">1</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/Shell/">
                        <span class="tag">Shell</span>
                        <span class="tag is-grey">1</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/Tensorflow/">
                        <span class="tag">Tensorflow</span>
                        <span class="tag is-grey">3</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/Tomcat/">
                        <span class="tag">Tomcat</span>
                        <span class="tag is-grey">2</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/Unix/">
                        <span class="tag">Unix</span>
                        <span class="tag is-grey">1</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/VSCode/">
                        <span class="tag">VSCode</span>
                        <span class="tag is-grey">1</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/WordPress/">
                        <span class="tag">WordPress</span>
                        <span class="tag is-grey">1</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/python/">
                        <span class="tag">python</span>
                        <span class="tag is-grey">8</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/ssh/">
                        <span class="tag">ssh</span>
                        <span class="tag is-grey">1</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/%E4%BB%A3%E7%A0%81%E5%AD%98%E6%A1%A3/">
                        <span class="tag">代码存档</span>
                        <span class="tag is-grey">2</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/%E5%8C%BB%E5%AD%A6%E5%9B%BE%E5%83%8F/">
                        <span class="tag">医学图像</span>
                        <span class="tag is-grey">2</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/%E5%A4%A7%E6%95%B0%E6%8D%AE/">
                        <span class="tag">大数据</span>
                        <span class="tag is-grey">2</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/%E5%B5%8C%E5%85%A5%E5%BC%8F-STM32/">
                        <span class="tag">嵌入式 - STM32</span>
                        <span class="tag is-grey">1</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/%E6%8B%A6%E6%88%AA%E5%99%A8/">
                        <span class="tag">拦截器</span>
                        <span class="tag is-grey">1</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/%E6%95%99%E7%A8%8B/">
                        <span class="tag">教程</span>
                        <span class="tag is-grey">2</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/%E7%89%B9%E5%BE%81%E5%B7%A5%E7%A8%8B/">
                        <span class="tag">特征工程</span>
                        <span class="tag is-grey">1</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/%E7%AC%AC%E4%B8%89%E6%96%B9%E5%BA%93/">
                        <span class="tag">第三方库</span>
                        <span class="tag is-grey">1</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/%E7%BA%A2%E7%90%83%E6%A3%80%E6%B5%8B/">
                        <span class="tag">红球检测</span>
                        <span class="tag is-grey">1</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/%E7%BC%96%E8%AF%91%E5%8E%9F%E7%90%86/">
                        <span class="tag">编译原理</span>
                        <span class="tag is-grey">2</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/%E8%A7%A3%E5%86%B3%E6%96%B9%E6%A1%88/">
                        <span class="tag">解决方案</span>
                        <span class="tag is-grey">6</span>
                    </a>
                </div>
                
                <div class="control">
                    <a class="tags has-addons" href="/tags/%E9%9A%8F%E7%AC%94/">
                        <span class="tag">随笔</span>
                        <span class="tag is-grey">4</span>
                    </a>
                </div>
                
            </div>
        </div>
    </div>
</div>
    
    
</div>

            </div>
        </div>
    </section>
    <!--
 * @Descripttion: 
 * @version: 
 * @Author: 王政乔(https://www.zhengqiao.wang/)
 * @Date: 2020-03-25 10:59:52
 * @LastEditors: 王政乔(https://www.zhengqiao.wang/)
 * @LastEditTime: 2020-03-26 10:51:19
 -->
<footer class="footer">

    <div class="container">
        <div class="level">
            <div class="level-start has-text-centered-mobile">
                <a class="footer-logo is-block has-mb-6" href="/">
                
                    王政乔|中国
                
                </a>
                <p class="is-size-7">
                <a href='http://www.beian.miit.gov.cn/' >豫ICP备18045451号-1</a>&nbsp;
                &copy; 2020 王政乔&nbsp;
                Powered by <a href="https://hexo.io/" target="_blank" rel="noopener">Hexo</a> & <a
                        href="https://github.com/ppoffice/hexo-theme-icarus" target="_blank" rel="noopener">Icarus</a>
                        
                
                </p>
            </div>
            <div class="level-end">
            
                <div class="field has-addons is-flex-center-mobile has-mt-5-mobile is-flex-wrap is-flex-middle">
                
                <p class="control">
                    <a class="button is-white is-large" target="_blank" rel="noopener" title="访问我的Gitee" href="https://gitee.com/JogerQiao">
                        
                        <i class="iconfont icon-gitee-fill-round"></i>
                        
                    </a>
                </p>
                
                <p class="control">
                    <a class="button is-white is-large" target="_blank" rel="noopener" title="我的邮箱" href="mailto:me@zhengqiao.wang">
                        
                        <i class="iconfont icon-mail"></i>
                        
                    </a>
                </p>
                
                <p class="control">
                    <a class="button is-white is-large" target="_blank" rel="noopener" title="Bilibili" href="https://space.bilibili.com/83542572">
                        
                        <i class="iconfont icon-bilibili-line"></i>
                        
                    </a>
                </p>
                
                <p class="control">
                    <a class="button is-white is-large" target="_blank" rel="noopener" title="知乎" href="https://www.zhihu.com/people/joger-81">
                        
                        <i class="iconfont icon-zhihu"></i>
                        
                    </a>
                </p>
                
                <p class="control">
                    <a class="button is-white is-large" target="_blank" rel="noopener" title="SZ" href="http://jun.zhengqiao.wang/">
                        
                        <i class="iconfont icon-setting"></i>
                        
                    </a>
                </p>
                
                </div>
            
            </div>
        </div>
    </div>
    <script>
        (function () {
            var bp = document.createElement('script');
            var curProtocol = window.location.protocol.split(':')[0];
            if (curProtocol === 'https') {
                bp.src = 'https://zz.bdstatic.com/linksubmit/push.js';
            }
            else {
                bp.src = 'http://push.zhanzhang.baidu.com/push.js';
            }
            var s = document.getElementsByTagName("script")[0];
            s.parentNode.insertBefore(bp, s);
        })();
    </script>

</footer>
    <script src="https://cdn.jsdelivr.net/npm/jquery@3.3.1/dist/jquery.min.js"></script>
<script src="https://cdn.jsdelivr.net/npm/moment@2.22.2/min/moment-with-locales.min.js"></script>
<script>moment.locale("zh-CN");</script>


<script>
var IcarusThemeSettings = {
    site: {
        url: 'https://www.zhengqiao.wang',
        external_link: {"enable":true,"exclude":[]}
    },
    article: {
        highlight: {
            clipboard: true,
            fold: 'unfolded'
        }
    }
};
</script>


<script src="https://cdn.jsdelivr.net/npm/clipboard@2.0.4/dist/clipboard.min.js" defer></script>





<script src="/js/animation.js"></script>



<script src="https://cdn.jsdelivr.net/npm/lightgallery@1.6.8/dist/js/lightgallery.min.js" defer></script>
<script src="https://cdn.jsdelivr.net/npm/justifiedGallery@3.7.0/dist/js/jquery.justifiedGallery.min.js" defer></script>
<script src="/js/gallery.js" defer></script>



<div id="outdated">
    <h6>Your browser is out-of-date!</h6>
    <p>Update your browser to view this website correctly. <a id="btnUpdateBrowser" href="http://outdatedbrowser.com/">Update
            my browser now </a></p>
    <p class="last"><a href="#" id="btnCloseUpdateBrowser" title="Close">&times;</a></p>
</div>
<script src="https://cdn.jsdelivr.net/npm/outdatedbrowser@1.1.5/outdatedbrowser/outdatedbrowser.min.js" defer></script>
<script>
    document.addEventListener("DOMContentLoaded", function () {
        outdatedBrowser({
            bgColor: '#f25648',
            color: '#ffffff',
            lowerThan: 'flex'
        });
    });
</script>


<script src="https://cdn.jsdelivr.net/npm/mathjax@2.7.5/unpacked/MathJax.js?config=TeX-MML-AM_CHTML" defer></script>
<script>
document.addEventListener('DOMContentLoaded', function () {
    MathJax.Hub.Config({
        'HTML-CSS': {
            matchFontHeight: false
        },
        SVG: {
            matchFontHeight: false
        },
        CommonHTML: {
            matchFontHeight: false
        },
        tex2jax: {
            inlineMath: [
                ['$','$'],
                ['\\(','\\)']
            ]
        }
    });
});
</script>


<a id="back-to-top" title="回到顶端" href="javascript:;">
    <i class="fas fa-chevron-up"></i>
</a>
<script src="/js/back-to-top.js" defer></script>














<script src="/js/main.js" defer></script>

    
    <div class="searchbox ins-search">
    <div class="searchbox-container ins-search-container">
        <div class="searchbox-input-wrapper">
            <input type="text" class="searchbox-input ins-search-input" placeholder="想要查找什么..." />
            <span class="searchbox-close ins-close ins-selectable"><i class="fa fa-times-circle"></i></span>
        </div>
        <div class="searchbox-result-wrapper ins-section-wrapper">
            <div class="ins-section-container"></div>
        </div>
    </div>
</div>
<script>
    (function (window) {
        var INSIGHT_CONFIG = {
            TRANSLATION: {
                POSTS: '文章',
                PAGES: '页面',
                CATEGORIES: '分类',
                TAGS: '标签',
                UNTITLED: '(无标题)',
            },
            CONTENT_URL: '/content.json',
        };
        window.INSIGHT_CONFIG = INSIGHT_CONFIG;
    })(window);
</script>
<script src="/js/insight.js" defer></script>
<link rel="stylesheet" href="/css/search.css">
<link rel="stylesheet" href="/css/insight.css">
    
</body>
</html>